lemon-mse 0.2.7 → 0.2.9

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 CHANGED
@@ -1 +1 @@
1
- var ro=Object.defineProperty;var ao=(t,e,s)=>e in t?ro(t,e,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[e]=s;var W=(t,e,s)=>ao(t,typeof e!="symbol"?e+"":e,s);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))a(n);new MutationObserver(n=>{for(const l of n)if(l.type==="childList")for(const i of l.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&a(i)}).observe(document,{childList:!0,subtree:!0});function s(n){const l={};return n.integrity&&(l.integrity=n.integrity),n.referrerPolicy&&(l.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?l.credentials="include":n.crossOrigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function a(n){if(n.ep)return;n.ep=!0;const l=s(n);fetch(n.href,l)}})();const uo=Vue.createApp,Q=Vue.defineComponent,v=Vue.unref,y=Vue.openBlock,b=Vue.createElementBlock,ue=Vue.createCommentVNode,X=Vue.renderList,$=Vue.Fragment,L=Vue.normalizeClass,c=Vue.createElementVNode,Ke=Vue.resolveComponent,O=Vue.withCtx,M=Vue.createVNode,Z=Vue.vShow,B=Vue.withDirectives,Re=Vue.resolveDynamicComponent,V=Vue.createBlock,co=Vue.KeepAlive,k=Vue.ref,Ce=Vue.onMounted,oe=Vue.watch,re=Vue.reactive,Ve=Vue.watchEffect,z=Vue.computed,ce=Vue.isRef,dt=Vue.vModelText,vo=Vue.withKeys,T=Vue.toDisplayString,Bt=Vue.onActivated,vt=Vue.resolveDirective,je=Vue.createTextVNode,F=Vue.withModifiers,xe=Vue.normalizeStyle,fo=Vue.shallowRef,at=Vue.nextTick,tt=Vue.onBeforeUnmount;Vue.h;const po=Vue.onDeactivated,mo=Vue.onUnmounted,Ue=Vue.useModel,Be=Vue.mergeModels,ho=Vue.renderSlot,Vt=Vue.useSlots,go=Vue.provide,yo=Vue.inject,wo=Vue.getCurrentInstance,Xe=(t,e)=>{let s=-1;const a=t.length,n=new Array(a);for(;++s<a;)n[s]=e(t[s]);return n},Ut=(t,e)=>{let s=-1;const a=t.length;for(;++s<a;)e(t[s])},xo=t=>{if(t.scrollTop>0)return!0;t.scrollTop=1;const e=!!t.scrollTop;return t.scrollTop=0,e},ko=async(t,e,s)=>{const a=[],n=[];for(const l of t){const i=Promise.resolve().then(()=>s(l));if(a.push(i),e<=t.length){const r=i.then(()=>n.splice(n.indexOf(r),1));n.push(r),n.length>=e&&await Promise.race(n)}}return Promise.all(a)},ft="https://lemonlive.deno.dev/api/",le=(t,e,s)=>(t=="douyin"&&(s?s.cookie=K[t]:s={cookie:K[t]}),pt(`${ft}${t}/${e}${s?"?"+new URLSearchParams(s).toString():""}`)),ct=async t=>{const e=Object.keys(t.follows);if(!e.length)return Promise.resolve(!1);if(t.id=="douyin"){(await ko(e,4,a=>le("douyin","getLiveStatus",{id:a}))).forEach((a,n)=>t.follows[e[n]].status=a[e[n]].status);return}await le(t.id,"getLiveStatus",{id:e.join(",")}).then(s=>Object.keys(s).forEach(a=>{t.follows[a].status=s[a].status}))},bo=t=>pt(`${ft}sync`,{method:"POST",body:t}),Co=t=>pt(`${ft}sync/${t}`),pt=(t,e)=>fetch(t,e).then(async s=>{const a=await s.json();return a.code!=200?Promise.reject(a.msg):a.data},s=>{Promise.reject("网络异常!")});k(!0);const j=[{name:"虎牙直播",icon:"https://www.huya.com/favicon.ico",id:"huya",categories:k([]),categoryActive:k(0),recommend:{page:1,hasMore:!0,list:k([])},search:{page:1,hasMore:!0,list:k([])},follows:re(Je("huya"))},{name:"斗鱼直播",icon:"https://www.douyu.com/favicon.ico",id:"douyu",categories:k([]),categoryActive:k(0),recommend:{page:1,hasMore:!0,list:k([])},search:{page:1,hasMore:!0,list:k([])},follows:re(Je("douyu"))},{name:"抖音直播",icon:"https://www.douyin.com/favicon.ico",id:"douyin",categories:k([]),categoryActive:k(0),recommend:{page:1,hasMore:!0,list:k([])},search:{page:1,hasMore:!0,list:k([])},follows:re(Je("douyin"))},{name:"哔哩直播",icon:"https://www.bilibili.com/favicon.ico",id:"bilibili",categories:k([]),categoryActive:k(0),recommend:{page:1,hasMore:!0,list:k([])},search:{page:1,hasMore:!0,list:k([])},follows:re(Je("bilibili"))}],ke=["huya","douyu","douyin","bilibili"],q=k(_e("volume",100)),G=k(_e("brightness",100)),We=t=>{q.value=t?Math.min(100,q.value+5):Math.max(0,q.value-5)},Mt=t=>{G.value=t?Math.min(200,G.value+10):Math.max(50,G.value-10)};function Je(t){const e=localStorage.getItem("follows-"+t);return e?JSON.parse(e):{}}function Le(t){const e=j.find(s=>s.id==t.siteId);return t.siteId=e.id,e.follows[t.roomId]={...t,stream:void 0,ws:void 0},localStorage.setItem("follows-"+t.siteId,JSON.stringify(e.follows)),Reflect.has(e.follows,t.roomId)}function _o(t,e){const s=j.find(a=>a.id==t);return delete s.follows[e],localStorage.setItem("follows-"+t,JSON.stringify(s.follows)),Reflect.has(s.follows,e)}function Io(){j.forEach(t=>{for(const e in t.follows)delete t.follows[e];localStorage.removeItem("follows-"+t.id)})}async function Tt(t,e){const s=t.categories;s.value.length||(s.value=await le(t.id,"getCategories"));for(const a of s.value)for(const n of a.list)if(n.cid==e)return n;return null}const w=re(_e("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:""}));Ve(()=>{be("dm-settings",w)});function _e(t,e){const s=localStorage.getItem(t);return s?JSON.parse(s):e}function be(t,e){localStorage.setItem(t,JSON.stringify(e))}const So=["#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"],Et=z(()=>w.blockWords.length==0?[]:w.blockWords.split(" ").map(t=>new RegExp(t))),K=re(_e("cookies",{}));Ve(()=>be("cookies",K));const P=k(0),we=k(_e("show-chat",!0)),He=k(_e("show-aside",!0));Ve(()=>be("show-chat",we.value));Ve(()=>be("show-aside",He.value));const Ao=VueRouter.createRouter,Mo=VueRouter.createWebHistory,mt=VueRouter.useRoute,ht=VueRouter.useRouter,To=VueRouter.onBeforeRouteUpdate,Eo={key:0,src:"https://live.douyin.com","pos-absolute":"",width:"0",height:"0","op-0":"","b-0":"",style:{"z-index":"-10"}},Oo={"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":""},jo={"h-full":"",class:"scrolly","md:px-3":""},Lo=Q({__name:"App",setup(t){const e=[{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"}],s=k(!0);Ce(()=>{document.querySelector("main").style.height=`calc(${window.innerHeight}px - 3.5rem)`,setTimeout(()=>s.value=!1,5e3)});const a=mt();return oe(a,()=>{const n=a.params.siteid;if(n==null)return;const l=ke.findIndex(i=>i==n);l!=-1&&(P.value=l)}),(n,l)=>{const i=Ke("router-link"),r=Ke("router-view");return y(),b($,null,[v(s)?(y(),b("iframe",Eo)):ue("",!0),B(c("div",Oo,[(y(),b($,null,X(e,u=>M(i,{to:u.link,"hover:text-amber":"","rounded-2":"","py-2":"","px-4":"","m-2":"",class:L({"text-amber":n.$route.path==u.link})},{default:O(()=>[c("div",{class:L(u.icon)},null,2)]),_:2},1032,["to","class"])),64))],512),[[Z,v(He)]]),c("main",{"mx-2":"","md:mx-0":"",class:L(["md:!h-100vh",{"md:ml-17.5":v(He),"!h-100vh":!v(He)}]),"pt-2":"","box-border":""},[c("div",jo,[M(r,null,{default:O(({Component:u})=>[(y(),V(co,{exclude:["play"]},[(y(),V(Re(u)))],1024))]),_:1})])],2)],64)}}}),Ro=t=>{const e=k(t);return[e,a=>e.value=a]},Bo=/scroll|auto|overlay/i;function Vo(t){return t.tagName!=="HTML"&&t.tagName!=="BODY"&&t.nodeType===1}function Uo(t,e=document.body){let s=t;for(;s&&s!==e&&Vo(s);){const{overflowY:a}=window.getComputedStyle(s);if(Bo.test(a))return s;s=s.parentNode}return e}function Po(t,e=document.body){const s=k();return Ce(()=>{t.value&&(s.value=Uo(t.value,e))}),s}const zo={key:0,"text-center":""},Fo={key:1,"text-center":""},ot=Q({__name:"list",props:{finshedText:{default:"没有更多了"},errorText:{default:"加载失败,点击重新加载"},immediate:{type:Boolean,default:!0},offset:{default:50}},emits:["load","refresh"],setup(t,{emit:e}){const s=t,a=k(0),[n,l]=Ro("normal"),i=k(),r=Po(i),u=e,f=()=>{if(a.value=r.value.scrollTop,n.value!="normal")return;r.value.scrollHeight-r.value.clientHeight-r.value.scrollTop<s.offset&&h()};Ce(()=>{s.immediate&&h(),r.value.addEventListener("scroll",f,{passive:!0})}),Bt(()=>{r.value.scrollTop=a.value,r.value.addEventListener("scroll",f)});const p=()=>{r.value.removeEventListener("scroll",f)};po(p),tt(p);let m;const h=()=>{l("loading"),u("load",l),clearTimeout(m),m=setTimeout(()=>{xo(r.value)||u("load",l)},2e3)};return(E,Y)=>(y(),b("div",{ref_key:"root",ref:i,"h-full":"","select-none":""},[ho(E.$slots,"default"),v(n)=="loading"?(y(),b("div",zo,"加载中...")):v(n)=="finshed"?(y(),b("div",Fo,T(s.finshedText),1)):v(n)=="loaderror"?(y(),b("div",{key:2,"text-center":"","cursor-pointer":"",onClick:h},T(s.errorText),1)):ue("",!0)],512))}}),$o=["data-id","data-site","href"],No={"pos-relative":"","text-rose-4":"","rounded-t-2":"","w-full":"","aspect-video":""},Do={block:"","h-full":"","rounded-2":"","select-none":""},Go={"pos-absolute":"","bottom-0":"","right-0":"","px-2":"","py-1":"","rounded-tl-2":"","bg-dark-6":""},Qo={"line-height-none":"","pos-absolute":"","top-0":"","right-0":"","px-1":"","py-1":"","rounded-tr-1":"","rounded-bl-2":"","bg-dark-6":""},Wo={key:0,"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":""},Jo={"px-2":"","text-truncate":"","leading-normal":""},Yo={"px-2":"","text-truncate":"","leading-normal":"","pb-2":""},st=Q({__name:"rooms",props:{list:{}},setup(t){let e;const s=ht(),a=k(),n=r=>{clearTimeout(e),e=setTimeout(()=>{const u=i("id",r.target,a.value);if(!u)return;const f=i("site",r.target,a.value);s.push(`/${f}/play/${u}`)},300)},l=r=>{var m;clearTimeout(e);const u=i("id",r.target,a.value);if(!u)return;const p=`/${i("site",r.target,a.value)}/play/${u}`;(m=window.open(p,"_blank"))==null||m.location},i=(r,u,f)=>{if(u==f)return null;const p=u.dataset[r];return p||i(r,u.parentElement,f)};return(r,u)=>{const f=vt("lazy");return r.list.value.length>0?(y(),b("div",{key:0,ref_key:"root",ref:a,grid:"","gap-4":"","p-2":"","justify-evenly":"","cursor-pointer":"","select-none":"","grid-cols-2":"","md:grid-cols-3":"","xl:grid-cols-4":"",class:"2xl:grid-cols-5",onClick:F(n,["prevent"]),onDblclick:F(l,["prevent"])},[(y(!0),b($,null,X(r.list.value,p=>(y(),b("a",{"data-id":p.roomId,"data-site":p.siteId,href:`/${p.siteId}/play/${p.roomId}`,key:`${p.siteId}-${p.roomId}`,shadow:"","rounded-2":"","b-2px":"","b-solid":"","b-transparent":"","hover:b-amber":"","overflow-hidden":""},[c("div",No,[B(c("img",Do,null,512),[[f,p.cover]]),c("div",Go,T(p.category),1),c("div",Qo,[u[0]||(u[0]=c("div",{class:"i-mdi-fire"},null,-1)),c("span",null,T(p.online),1)]),p.status?ue("",!0):(y(),b("div",Wo," 未开播 "))]),c("div",Jo,T(p.title),1),c("div",Yo,T(p.nickname),1)],8,$o))),128))],544)):ue("",!0)}}}),qo={"h-full":""},Ho={flex:"","py-1":"","px-2":"","text-lg":"","gap-2":""},Zo={grow:"","text-center":""},Ko={"hover:text-amber":""},Xo={key:0,class:"h-[calc(100%-3.25rem)] scrolly"},es=Q({__name:"categoryRooms",setup(t){const e=mt(),s=k(""),a=k(),n={list:k([]),page:1,hasMore:!0},l=f=>{const{site:p,id:m}=e.meta;le(p.id,"getCategoryRooms",{id:m,pid:a.value,page:n.page}).then(h=>{if(n.list.value=n.list.value.concat(h.list),n.hasMore=h.hasMore,K[p.id]||(K[p.id]=h.cookie),!h.hasMore)return f("finshed");n.page++,f("normal")},h=>{s.value=h,f("loaderror")})},i=k(!1),r=()=>{document.querySelector("#goTop").click(),i.value=!0;const{site:f,id:p}=e.meta;le(f.id,"getCategoryRooms",{id:p,pid:a.value,page:n.page}).then(m=>{n.list.value=m.list,n.hasMore=m.hasMore,n.page++,K[f.id]||(K[f.id]=m.cookie)},m=>{s.value=m}).finally(()=>i.value=!1)};let u=e.fullPath;return Tt(e.meta.site,e.meta.id).then(f=>{s.value=(f==null?void 0:f.name)||null,a.value=f==null?void 0:f.pid}),Bt(function(){u!=e.fullPath&&(u=e.fullPath,Tt(e.meta.site,e.meta.id).then(f=>{s.value=(f==null?void 0:f.name)||null,a.value=f==null?void 0:f.pid}),n.list.value=[],n.page=1,n.hasMore=!0)}),(f,p)=>{var E;const m=st,h=ot;return y(),b("div",qo,[c("div",Ho,[c("div",{"hover:text-amber":"",onClick:p[0]||(p[0]=(...Y)=>f.$router.back&&f.$router.back(...Y)),class:"i-ri-arrow-left-line"}),c("div",Zo,[c("span",Ko,T(`${(E=v(e).meta.site)==null?void 0:E.name} ${v(s)==null?"分区不存在":v(s)==""?"加载中":v(s)}`),1)]),c("div",{"mr-7":"","md:mr-24":"","hover:text-amber":"",onClick:r,class:L(["i-ri-refresh-line",{"animate-spin":v(i)}])},null,2)]),v(s)?(y(),b("div",Xo,[(y(),V(h,{key:v(u),onLoad:l},{default:O(()=>[M(m,{list:n.list},null,8,["list"])]),_:1}))])):ue("",!0)])}}}),Pt=Symbol("tabs"),ts=(t,e)=>{const s=re([]);return go(t,Object.assign({link:l=>{l.proxy&&s.push(l.proxy)},unlink:l=>{const i=s.indexOf(l.proxy);s.splice(i,1)},children:s},e)),s},zt=t=>{const e=yo(t);if(e==null)return{parent:e,index:k(-1)};const s=wo(),{link:a,unlink:n,children:l}=e;a(s),mo(()=>n(s));const i=z(()=>l.indexOf(s.proxy));return{parent:e,children:l,index:i}},os={class:"h-full","box-border":""},ss={"w-full":"","box-border":"","text-sm":"","sm:text-base":""},ns=["onClick"],ls={class:"h-[calc(100%-2rem)] scrolly","box-border":"","pt-1":""},Pe=Q({__name:"tabs",props:Be({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:Be(["tabClick"],["update:active"]),setup(t,{emit:e}){const s=Ue(t,"active"),a=t,n=e,l=u=>{s.value=u,n("tabClick",u)},i=ts(Pt,{active:s,props:a}),r=z(()=>Xe(i,u=>u.title));return(u,f)=>{const p=Ke("router-link");return y(),b("div",os,[c("div",ss,[c("div",{flex:"",p1:"","sm:gap-1":"","text-center":"","h-8":"","box-border":"","lg:justify-center":"",class:L([[v(i).length>5||u.grow?"":u.justify],"scrollx"])},[a.link?(y(!0),b($,{key:0},X(v(r),(m,h)=>(y(),V(p,{"px-1":"","sm:px-2":"","box-border":"","shrink-0":"",rounded:"","py-1":"","line-height-none":"","text-centercursor-pointer":"","hover:text-amber":"","cursor-pointer":"",class:L({"text-amber":s.value==h,grow:u.grow}),to:v(i)[h].href},{default:O(()=>[je(T(m),1)]),_:2},1032,["class","to"]))),256)):(y(!0),b($,{key:1},X(v(r),(m,h)=>(y(),b("a",{"px-1":"","sm:px-2":"","box-border":"","shrink-0":"",rounded:"","py-1":"","line-height-none":"","text-centercursor-pointer":"","hover:text-amber":"","cursor-pointer":"",class:L({"text-amber":s.value==h,grow:u.grow}),onClick:E=>l(h)},T(m),11,ns))),256))],2)]),c("div",ls,[(y(),V(Re(u.$slots.default)))])])}}}),is=Symbol("swipe"),rs={"w-full":"","h-full":"","shrink-0":"","pos-relative":""},as=Q({__name:"swipeItem",emits:["inited"],setup(t,{emit:e}){const s=k(!1),{parent:a,children:n,index:l}=zt(is),i=Vt(),r=e,u=z(()=>(a==null?void 0:a.active.value)==l.value?(s.value||(s.value=!0,r("inited",l.value)),!0):l.value==(a.active.value==0?n.length-1:a.active.value-1)||l.value==(a.active.value==n.length-1?0:a.active.value+1)),f=z(()=>u.value||s.value||!(a!=null&&a.props.lazy)?i.default:null);return(p,m)=>B((y(),b("div",rs,[(y(),V(Re(v(f))))],512)),[[Z,v(u)]])}}),us={"h-full":"","w-full":"","shrink-0":"",class:"scrolly"},ze=Q({__name:"tab",props:{title:{},href:{}},emits:["inited"],setup(t,{expose:e,emit:s}){const a=t,n=k(!1),l=Vt(),{parent:i,index:r,children:u}=zt(Pt),f=s,p=z(()=>(i==null?void 0:i.active.value)==r.value?(n.value||(n.value=!0,f("inited",r.value)),!0):(i==null?void 0:i.props.swipeable)&&(r.value==(i.active.value==0?u.length-1:i.active.value-1)||r.value==(i.active.value==u.length-1?0:i.active.value+1))),m=z(()=>p.value||i!=null&&i.props.swipeable||n.value||!(i!=null&&i.props.lazy)?l.default:null);return e({title:a.title}),(h,E)=>{var C,_;const Y=as;return B((y(),b("div",us,[(C=v(i))!=null&&C.props.swipeable?(y(),V(Y,{key:0},{default:O(()=>[(y(),V(Re(v(m))))]),_:1})):(y(),V(Re(v(m)),{key:1}))],512)),[[Z,v(p)||((_=v(i))==null?void 0:_.props.swipeable)]])}}}),cs={key:0,"text-center":""},ds={"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":"",lass:"2xl:grid-cols-18"},vs={"w-full":"","aspect-ratio-square":"",rounded:""},fs={"w-full":"","text-truncate":"","text-xs":"","md:text-sm":"","text-center":""},ps=Q({__name:"category",setup(t){const e=z(()=>j[P.value].id),s=k(),a=n=>{j[n].categories.value.length||(s.value="加载中...",le(e.value,"getCategories").then(l=>{s.value=null,j[n].categories.value=l},l=>s.value=l))};return(n,l)=>{const i=Ke("router-link"),r=ze,u=Pe,f=vt("lazy");return y(),V(u,{active:v(P),"onUpdate:active":l[0]||(l[0]=p=>ce(P)?P.value=p:null),link:!0,"pt-1":""},{default:O(()=>[(y(!0),b($,null,X(v(j),p=>(y(),V(r,{title:p.name,href:`/${p.id}/category`,onInited:a,key:p.id},{default:O(()=>[v(s)?(y(),b("div",cs,T(v(s)),1)):(y(),V(u,{key:1,active:p.categoryActive.value,"onUpdate:active":m=>p.categoryActive.value=m},{default:O(()=>[(y(!0),b($,null,X(p.categories.value,m=>(y(),V(r,{title:m.name,key:m.id},{default:O(()=>[c("div",ds,[(y(!0),b($,null,X(m.list,h=>(y(),V(i,{to:`/${p.id}/category/${h.cid}`,"cursor-pointer":""},{default:O(()=>[B(c("img",vs,null,512),[[f,h.pic]]),c("div",fs,T(h.name),1)]),_:2},1032,["to"]))),256))])]),_:2},1032,["title"]))),128))]),_:2},1032,["active","onUpdate:active"]))]),_:2},1032,["title","href"]))),128))]),_:1},8,["active"])}}}),ms={"text-center":"","py-1":""},hs={class:"w-60% max-w-md pos-relative inline-block"},gs={class:"h-[calc(100%-3rem)]"},ys={key:1},ws={key:1},xs=Q({__name:"search",setup(t){const e=k(""),s=z(()=>j[P.value]),a=k(),n=()=>{if(!e.value)return Promise.resolve();const p=s.value.search;p.list.value=[],p.page=1,p.hasMore=!0,a.value="搜索中...";const m=s.value.id;return le(m,"searchRooms",{page:p.page,kw:e.value}).then(h=>{p.list.value=h.list,p.hasMore=h.hasMore,p.page+=1,a.value="finished",K[m]||(K[m]=h.cookie)},h=>a.value=h)},l=p=>{const m=s.value.search,h=s.value.id;p("loading"),le(h,"searchRooms",{page:m.page,kw:e.value}).then(E=>{if(m.list.value=m.list.value.concat(E.list),m.hasMore=E.hasMore,K[h]||(K[h]=E.cookie),!m.hasMore)return p("finshed");m.page+=1,p("normal")},E=>{p("loaderror")})},i=p=>{r.push(`/${ke[p]}/search`),!u()&&j[p].search.page==1&&n()},r=ht(),u=()=>{if(e.value)return/^[\d]*$/.test(e.value)?(r.push(`/play/${s.value.id}/${e.value}`),!0):!1},f=()=>{u()||(j.forEach(p=>p.search.page=1),n())};return(p,m)=>{const h=st,E=ot,Y=ze,C=Pe;return y(),b($,null,[c("div",ms,[c("div",hs,[B(c("input",{"md:text-4":"",type:"text","onUpdate:modelValue":m[0]||(m[0]=_=>ce(e)?e.value=_:null),"box-border":"","w-full":"","py-2.5":"","pl-3":"","pr-9":"","text-white":"","bg-transparent":"","b-1":"","b-green":"","rounded-6":"","outline-0":"",onKeydown:vo(f,["enter"]),placeholder:"请输入房间号或关键字"},null,544),[[dt,v(e),void 0,{trim:!0}]]),c("div",{class:"i-ri-search-line top-50%",absolute:"","right-3":"",onClick:f,style:{transform:"translateY(-50%)"}})])]),c("div",gs,[M(C,{active:v(P),"onUpdate:active":m[1]||(m[1]=_=>ce(P)?P.value=_:null),onTabClick:i},{default:O(()=>[(y(!0),b($,null,X(v(j),_=>(y(),V(Y,{title:_.name,key:_.id},{default:O(()=>[v(a)=="finished"?(y(),b($,{key:0},[_.search.list.value.length?(y(),V(E,{key:0,onLoad:l},{default:O(()=>[M(h,{list:_.search.list},null,8,["list"])]),_:2},1024)):(y(),b("div",ys," 什么也没有找到 "))],64)):(y(),b("div",ws,T(v(a)),1))]),_:2},1032,["title"]))),128))]),_:1},8,["active"])])],64)}}}),ks={flex:"","items-center":""},bs={"grow-1":"","justify-center":"","gap-2":"","p-2":"",flex:""},Cs={"pos-relative":"",flex:"","gap-2":""},_s={"pos-absolute":"","top-0":"","right-0":"",style:{transform:"translateX(150%)"},"rounded-6":"","bg-white":"",shadow:"","text-amber":""},Is={class:"bg-gray-7 gap-4 p-12 rounded-2 flex flex-col shadow relative mt-30"},Ss={class:"flex justify-center items-center"},As={class:"flex gap-4"},Ms={class:"py-2 min-w-16"},Ts={class:"flex gap-4"},Es={class:"py-2 min-w-16"},Os={class:"h-[calc(100%-3rem)]"},js=Q({__name:"follow",setup(t){const e=Xe(j,_=>({name:_.name,list:z(()=>Object.values(_.follows).sort(S=>S.status?-1:0))}));e.unshift({name:"全部",list:z(()=>j.map(_=>Object.values(_.follows)).flat().sort(_=>_.status?-1:0))});const s=k(0),a=()=>{var S;if(l.value)return;const _=s.value;l.value=!0,_==0?Promise.all(Xe(j,ct)).finally(n):(S=ct(j[_-1]))==null||S.finally(n)},n=()=>setTimeout(()=>l.value=!1,300),l=k(!1),i=k(""),r=k(!1),u=k([]),f=k(!1),p=()=>setTimeout(()=>f.value=!1,300),m=()=>{f.value||(f.value=!0,bo(JSON.stringify(e[0].list.value)).then(_=>{i.value=_,u.value=e[0].list.value}).finally(p))},h=()=>{if(!f.value){if(!/^\d{4}$/.test(i.value))return i.value="";f.value=!0,Co(i.value).then(_=>{u.value=_}).finally(p)}},E=()=>{if(!f.value){if(f.value=!0,i.value.startsWith("[")){try{const _=JSON.parse(i.value);Ut(_,S=>{/^\d+$/.test(S.roomId)&&Le({siteId:S.siteId,roomId:S.roomId,cover:S.face,nickname:S.userName})})}catch{i.value="合并失败"}return p()}u.value.forEach(_=>Le(_)),p()}},Y=()=>{f.value||(f.value=!0,Io(),u.value.forEach(_=>Le(_)),p())};a();const C=_=>_("finshed");return(_,S)=>{const $e=st,ee=ot,ve=ze,fe=Pe;return y(),b($,null,[c("div",ks,[c("div",bs,[c("div",Cs,[S[6]||(S[6]=je("关注用户 ")),c("button",{class:"bg-green-5 rounded border-none cursor-pointer",onClick:S[0]||(S[0]=se=>r.value=!0)},"同步"),c("button",{class:"bg-green-5 rounded border-none cursor-pointer",onClick:a},"刷新"),B(c("div",_s,S[5]||(S[5]=[c("div",{class:"i-ri-refresh-line animate-spin"},null,-1)]),512),[[Z,v(l)]])]),B(c("div",{class:"absolute z-10 top-0 left-0 right-0 bottom-0 flex justify-center items-start",onClick:S[3]||(S[3]=F(se=>r.value=!1,["self"]))},[c("div",Is,[c("div",Ss,[S[8]||(S[8]=c("div",{class:"text-8"},"同步",-1)),B(c("div",null,S[7]||(S[7]=[c("div",{class:"i-ri-refresh-line animate-spin"},null,-1)]),512),[[Z,v(f)]])]),B(c("input",{class:"outline-none p-2 border-none rounded-2 flex-1","onUpdate:modelValue":S[1]||(S[1]=se=>ce(i)?i.value=se:null),type:"text",placeholder:"key"},null,512),[[dt,v(i)]]),c("div",As,[c("div",Ms,"本地 "+T(v(e)[0].list.value.length),1),c("div",{onClick:E,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"}," 合并 "),c("div",{onClick:Y,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"覆盖")]),c("div",Ts,[c("div",Es,"云端 "+T(v(u).length),1),c("div",{onClick:h,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"拉取"),c("div",{onClick:m,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"推送")]),S[9]||(S[9]=c("div",null,[c("div",null,"1. key 有效期 10 分钟"),c("div",null,"2. 拉取需要输入 key"),c("div",null,"3. 推送自动生成 key ")],-1)),c("div",{onClick:S[2]||(S[2]=F(se=>r.value=!1,["stop"])),class:"i-ri-close-circle-line absolute right-2 top-2"})])],512),[[Z,v(r)]])])]),c("div",Os,[M(fe,{active:v(s),"onUpdate:active":S[4]||(S[4]=se=>ce(s)?s.value=se:null)},{default:O(()=>[(y(!0),b($,null,X(v(e),se=>(y(),V(ve,{title:se.name},{default:O(()=>[M(ee,{onLoad:C,"finshed-text":""},{default:O(()=>[M($e,{list:se.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["title"]))),256))]),_:1},8,["active"])])],64)}}}),Ls=Q({__name:"index",setup(t){const e=z(()=>j[P.value].id),s=a=>{const n=j[P.value].recommend;le(e.value,"getRecommendRooms",{page:n.page}).then(l=>{if(n.list.value=n.list.value.concat(l.list),n.hasMore=l.hasMore,K[e.value]||(K[e.value]=l.cookie),!n.hasMore)return a("finshed");n.page++,a("normal")},()=>a("loaderror"))};return(a,n)=>{const l=st,i=ot,r=ze,u=Pe;return y(),V(u,{active:v(P),"onUpdate:active":n[0]||(n[0]=f=>ce(P)?P.value=f:null),link:!0,"pt-1":""},{default:O(()=>[(y(!0),b($,null,X(v(j),f=>(y(),V(r,{href:`/${f.id}`,key:f.id,title:f.name,"pos-relative":""},{default:O(()=>[M(i,{onLoad:s,"h-full":""},{default:O(()=>[M(l,{list:f.recommend.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["href","title"]))),128))]),_:1},8,["active"])}}}),Rs=Q({__name:"switch",props:{value:{type:Boolean,required:!0},valueModifiers:{}},emits:["update:value"],setup(t){const e=Ue(t,"value");return(s,a)=>(y(),b("div",{"pos-relative":"",style:{transition:"background-color .3s"},onClick:a[0]||(a[0]=()=>e.value=!e.value),"w-12":"","inline-block":"","cursor-pointer":"","rounded-6":"","h-6":"",class:L([e.value?"bg-amber":"bg-gray-4"])},[c("div",{"w-6":"","h-full":"","rounded-6":"","bg-white":"",style:xe([{transition:"transform .3s"},e.value?"transform:translateX(1.5rem)":""])},null,4)],2))}}),Bs={"rounded-4":"",flex:"","bg-gray-7":"","w-min":"","p-2":"","py-1":"","gap-2":""},Vs=Q({__name:"stepper",props:Be({max:{},min:{},step:{}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(t){const e=t,s=Ue(t,"value"),a=()=>s.value=Math.min(s.value+e.step,e.max),n=()=>s.value=Math.max(s.value-e.step,e.min);return(l,i)=>(y(),b("div",Bs,[c("div",{class:"i-ri-subtract-fill",onClick:n}),c("div",null,T(s.value),1),c("div",{class:"i-ri-add-fill",onClick:a})]))}});function Us(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}const Ze=Us(),Ps=t=>Ze?t.touches==null?t:t.touches[0]||t.changedTouches[0]:t,zs=Q({__name:"slider",props:Be({max:{default:100},min:{default:0},width:{default:30},height:{default:100}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(t){const e=t,s=Ue(t,"value"),a=k(),n=e.width<e.height;let l;const i=m=>{m.stopPropagation(),f(m),document.addEventListener("mousemove",f,!0),document.addEventListener("mouseup",p,!0)},r=z(()=>(s.value-e.min)/(e.max-e.min)*100),u=z(()=>{const m=100-r.value,h=`top:${m}%`,E=`left:${m}%`;return n?{loaded:h,indicator:h}:{loaded:`${E};transform:translateX(-100%)`,indicator:E}}),f=m=>{m.stopPropagation(),m=Ps(m);const E=100-(Math.min(n?l.height:l.width,Math.max(0,n?m.clientY-l.y:m.clientX-l.x))/(n?l.height:l.width)*100|0);s.value=((e.max-e.min)*E|0)/100+e.min|0},p=m=>{m.stopPropagation(),document.removeEventListener("mousemove",f,!0),document.removeEventListener("mouseup",p,!0)};return Ce(()=>{l=a.value.getBoundingClientRect(),a.value.addEventListener("mousedown",i,!0)}),tt(()=>{a.value.removeEventListener("mousedown",i,!0)}),(m,h)=>(y(),b("div",{"cursor-pointer":"",style:xe({width:`${e.width}px`,height:`${e.height}px`}),class:L(n?" py-4 ":"px-4"),flex:"","justify-center":""},[c("div",{"w-full":"","h-full":"","pos-relative":"",flex:"","justify-center":"","items-center":"",ref_key:"root",ref:a,onClick:f},[c("div",{"bg-gray":"","pos-relative":"","overflow-hidden":"",class:L(n?"h-full w-2px":"w-full h-2px")},[c("div",{"w-full":"","bg-amber":"","h-full":"","pos-absolute":"",style:xe(v(u).loaded)},null,4)],2),c("div",{"pos-absolute":"","w-12px":"","h-12px":"","bg-amber":"","rounded-2":"",style:xe(v(u).indicator),class:L(n?"-mt-6px":"-ml-6px")},null,6)],512)],6))}}),Fs={key:0,"z-1":"",fixed:"","top-0":"","bottom-0":"","left-0":"","right-0":"","bg-transparent":"","data-index":"-1"},$s={"p-1":"","data-index":"-1","hover:text-amber":""},Ns={"text-center":"","z-1":"","pos-absolute":"","top-0":"",class:"left-50%","w-max":"",style:{transform:"translate3d(-50%,-100%,0)"}},Ds=["data-index"],Gs=Q({__name:"select",props:Be(["list"],{active:{required:!0},activeModifiers:{}}),emits:["update:active"],setup(t){const e=Ue(t,"active"),s=k(!1),a=n=>{const l=n.target.dataset.index;l&&(l!="-1"&&(e.value=parseInt(l)),s.value=!s.value)};return(n,l)=>(y(),b("div",{"inline-block":"","pos-relative":"",onClick:a,"cursor-pointer":"","text-center":""},[v(s)?(y(),b("div",Fs)):ue("",!0),c("div",$s,T(t.list[e.value]),1),B(c("div",Ns,[(y(!0),b($,null,X(t.list,(i,r)=>(y(),b("div",{"data-index":r,class:L({"text-amber":r==e.value}),"p-1":"","hover:text-amber":""},T(i),11,Ds))),256))],512),[[Z,v(s)]])]))}}),Ot="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAMAAACahl6sAAAAAXNSR0IArs4c6QAAAEVQTFRFR3BM//////////////b4/////////////////////9Dd////////////+3GZ/HGZ/HGZ/HCZ/HGZ/HGZ/HGZ////+3GZG7vCKwAAABV0Uk5TAPEvsA6dhsxqVwYgQt7qaUAelc+1KF61kQAACS5JREFUeNrtnYmSozgMhjE2vsCdhIS8/6NOID0Jh40lH0C6oq3aqt3JGD4sS79kjqL42te+9rWvfZgxxWnFGx0/UqlUw3bDqEg3mJFxA9X8ORBtduEoTfcyGnM1FUkzTijH+/D9GYS7lxqPIzYn0aKbGA8dqJmOQ7cGkd3MysCFZmbjqI1BxBzEhDkXnY8jtuWou4XxJBPbdduukmZ5AiHOVZPlMNvGYGUBwTuXFpZh5O4zgncubhtF7b1G8M5lvRobu1Zhc4pOoJyrNrYxiN4WRHbRzkWtQ1RbZ0QR61z2S0HqzbWW9Tzgkask1gFksbnxKOfS9hmlxQ4W5VzVQRwr1rnskbfbp7KKcC5GuiQZNVNNAnYubY+8Qu8EEuxcjshbFrtZmHPZ+feIvHHOxcxxIm+Uc9kjr2G7ggQ4lzpU5A13rvpYkdfnXO5IerTIG+pc/EDSBORcjlOryeEir8+5qLQZPULk1XXZNEo9TodzXlUVpVQIYYz9IiONEGMeoz3GfIzMueRSKqWask68eEpZiW4fE1Sm0i5NRbp9jVTxaYZJ0x3BjIxK/YyT7ihGeDjKQWbjNSuBXciadkczGpI5FemOZwQ/KbI7piHlpabdUQ218XpgDhTJoTkwJJVfGk21Ee8VoeqtGazsre6N9VYM/x7+e/iT54+G38uldiMk1TqxrnNC+UPElf2prV0Q8MVa/aHusR/AilMSrvtLq9jRr6NvUs29jqStUg+iI5ftGiL3bXEwuUCB3OuxqEarnTs1vadV+GVSx+fSHLbQGV6xMou8pi6OYfO9U4pb6YfhWJKUmAk5EMeChGJWSFkcyUrEKuEH7De5zm41cJnNG5kacZBpM9CAJy9th5w1jrhawW+4baCOz3PdzKbVQ2hYSQSq3SOAviWy3HA0UDg2c/77gOGgwKJgcUuTDPfpjERfteoDkPtppmcIWyKecRldM20vChZXfbzjDvIAClokChF72Wrpw+zHXsRBib1nQoGcnyOSIRxkXBdI96IMKJY4qMTVqUDGV5FM/kCX6CWpQd5PgekGCTIel7uuHFRFGEjYEogsggEZ7bhN9uRq11QBM4nzYhPEzYUYkPGaruImZOr+kHPjKUG0sYhWPYq98HsIOUAAlxjliwIZi6TKdk5wFaEAkVVhFKMuFyZXbtUXS5DRykHs6zaAk5TImkpP/pkcgzmOT3htmxBEIQpwGy0jH39YAxlC8GQjsA7bKoAsZA4ICCiQRrytX+5CzP7H/1D/Nj8TAKRC5EMQiMJ32qsUGZF+BIjwg4jI8nAOorOAUP9ZgmTM7jMC8BvS4cq1fUAqb42oY+/N2wbEH1tZbG9umzXiz3Z1apAiP0jtBVFJQYhVYjCLv/hB/KqxRIKUYmZmE5DGC9JgxG/hfAjEtkZ8IDoUpEkBorz1iA2kjp2R0nuaCqfitQwCiZ4R/wpAgjhuRs6+RvwxyR/XVtoA262RiQApwzLNSht2uxkZX0CTpEAUcJBx6WStpwgCZPQspvL7PKA9YxAgCTP7aFgOyP0AkNGCWliRT2sNqXj1plPkjDB/NZkL5BG6lCoj9LEjngvnlls2kEih7xACdPsZSQmivAc/wowQ/8+lv5r8DBDulfw6Tx5JUNU7ft54ZyRpZk89I9QrMDNprdQgwi9nPmNGjPe3R5gRQPgl/jZxlgoxNQjzt4k/Y0beV1ZYnpxsjrJG/KKxAeS1N8gbcXQU2yOjKUBwMl5hQDbN7MgKUfrPJ7fWOp/atj3ryJqd7z0j5+t9sJ9THEi1M8jp/rKbjmkH0X1BRhz3exsDIvwPD2VcIxOO+/3sjkNeELPnjMw47teIlmn/fNfc6KzWygVyvs/tEtONX0uS/H+vY2EjB7b8qYLc/Xv+WYCMI5cuk4N4mumBjzxZOCYg6B2rnUAuFo4pSPRm6GhN5AOxckzDFksIIiHbGywZx88kJUbfMAACiZuRy9XGcT+5d1COCcLsHFftBqniQFQWEG3n+LmsJOsgEDkGCX/Tgssb9M3OcV6TT/SAIHaO+3lVB4o4kCYDSAvliL4VcFRsZQBxcJzim79rIKUFhND+RQScmiAQBMe0eg3JVtW4CpiCDA/p/T5zWHvegMMBwn2NA33HwIpvshlINRtOGRwIigN3b/x61TjNSmY5GKsQIPps52j9uSpM/k762m8Q+3sNFBwEyREvfyd97ddulOs1Jko4TMI4boC+dJjYquOyEKaQsjSBEoqtJk4XOHSJXbgvhKJTbAWci0y6N7tagNyvDNqrMjFBi2fnuMDboDHd/GQPXl+Awn0ttSMz4qSZn+qRfhbGgc2Iqil/PZWV3IAuwvl0Op2TF1KLv1fiEslzTRCyeAuoS3Gefn43AoDP5UILqfWM6F+wHNf3vLzP63YJ57hDZpSg4q9zG7H0+snVL651G86BrBG1o3aigMLo6vWuGI5JjUhwPx9lIOvVviAUBraQ8nh9ickcI44atKWxovnwBcj6mUlccPjvVwzaAmnzcUwrEoDaWtR5wpl9roh6wsXRwjPQ5LUj/sgyLfPE2ktarogLfI7lmG1xAnxLST68YbHi0vOtzBbuKuhCyrdIkn5T6gQOpgGFlGeRJH2/lv4BklxScMx8K+kb9k8w4RRUSHlTQ9JXhbUQKZuKY/4doKRfobj5SQILKYCkTUnikLOjspWl41h8xyHlgvftnOmEHMsqgydcJw7P+Y1I4YWU/bLNdYdIGLtWY+stRrhDmrIx79AHkrSxBQhAQc3fy5KnAdpm4LB/5EXwRB8edympSOFuBXF8gaYj5vk6bz5856QZXpFdM5aGJD1H31ZA7mT2Ly03zz2Ep43uRuO9KeavNjJwFLrpEhuRASRtAk9ukn8iovJ3FjJw5CBRSJJbojhZp/68kAB0ESMKkJUUzxOT1BiSW8oKokn7aZsSICDDCxDPpgfJBeISkFk4iqSff5r3MhyyC7CzFjgrKtHXSDhQQAYXIIBpUVX8vFh62w4BmY1jeHchaySv+m+dBH6mzlrVnFMWUkFk/XdOmvfH+J7tRvr8qEvPOhh5mRFSgwXkhhyrUxfb7ToCR4q+3adyzGXXqSj+BMknc7y237eNV1ns0j7kys/tpIs/YH8C4mtf+9rXvva1r33tj9o/Lzzyu+swTmIAAAAASUVORK5CYII=",jt="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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",Ye=window.Flv,Qs=window.pako.ungzip;function Ws(t){return Js(yt(t))}function Js(t){let e={};e:for(;!Se(t);){let s=U(t);switch(s>>>3){case 0:break e;case 1:{let a=gt(t);(e.messagesList||(e.messagesList=[])).push(Ys(t)),t.limit=a;break}case 8:{e.heartbeatDuration=ae(t,!0);break}case 9:{e.needAck=!!J(t);break}default:Ie(t,s&7)}}return e}function Ys(t){let e={};e:for(;!Se(t);){let s=U(t);switch(s>>>3){case 0:break e;case 1:{e.method=de(t,U(t));break}case 2:{e.payload=Nt(t,U(t));break}case 3:{e.msgId=ae(t,!1);break}case 4:{e.msgType=U(t);break}case 5:{e.offset=ae(t,!1);break}case 6:{e.needWrdsStore=!!J(t);break}case 7:{e.wrdsVersion=ae(t,!1);break}case 8:{e.wrdsSubKey=de(t,U(t));break}default:Ie(t,s&7)}}return e}function qs(t){return Hs(yt(t))}function Hs(t){let e={};e:for(;!Se(t);){let s=U(t);switch(s>>>3){case 0:break e;case 2:{let a=gt(t);e.user=Zs(t),t.limit=a;break}case 3:{e.content=de(t,U(t));break}default:Ie(t,s&7)}}return e}function Zs(t){let e={};e:for(;!Se(t);){let s=U(t);switch(s>>>3){case 0:break e;case 3:{e.nickName=de(t,U(t));break}default:Ie(t,s&7)}}return e}function Ks(t){let e=$t();return Xs(t,e),an(e)}function Xs(t,e){let s=t.seqId;s!==void 0&&(H(e,8),qe(e,s));let a=t.logId;a!==void 0&&(H(e,16),qe(e,a));let n=t.service;n!==void 0&&(H(e,24),qe(e,n));let l=t.method;l!==void 0&&(H(e,32),qe(e,l));let i=t.headersList;if(i!==void 0)for(let p of i){H(e,42);let m=$t();on(p,m),H(e,m.limit),cn(e,m),rn(m)}let r=t.payloadEncoding;r!==void 0&&(H(e,50),et(e,r));let u=t.payloadType;u!==void 0&&(H(e,58),et(e,u));let f=t.payload;f!==void 0&&(H(e,66),H(e,f.length),un(e,f))}function en(t){return tn(yt(t))}function tn(t){let e={};e:for(;!Se(t);){let s=U(t);switch(s>>>3){case 0:break e;case 1:{e.seqId=ae(t,!0);break}case 2:{e.logId=ae(t,!0);break}case 3:{e.service=ae(t,!0);break}case 4:{e.method=ae(t,!0);break}case 5:{let a=gt(t);(e.headersList||(e.headersList=[])).push(sn(t)),t.limit=a;break}case 6:{e.payloadEncoding=de(t,U(t));break}case 7:{e.payloadType=de(t,U(t));break}case 8:{e.payload=Nt(t,U(t));break}default:Ie(t,s&7)}}return e}function on(t,e){let s=t.key;s!==void 0&&(H(e,10),et(e,s));let a=t.value;a!==void 0&&(H(e,18),et(e,a))}function sn(t){let e={};e:for(;!Se(t);){let s=U(t);switch(s>>>3){case 0:break e;case 1:{e.key=de(t,U(t));break}case 2:{e.value=de(t,U(t));break}default:Ie(t,s&7)}}return e}function gt(t){let e=U(t),s=t.limit;return t.limit=t.offset+e,s}function Ie(t,e){switch(e){case 0:for(;J(t)&128;);break;case 2:ut(t,U(t));break;case 5:ut(t,4);break;case 1:ut(t,8);break;default:throw new Error("Unimplemented type: "+e)}}let nn=new Float32Array(1);new Uint8Array(nn.buffer);let ln=new Float64Array(1);new Uint8Array(ln.buffer);let Ft=[];function $t(){const t=Ft.pop();return t?(t.offset=t.limit=0,t):{bytes:new Uint8Array(64),offset:0,limit:0}}function rn(t){Ft.push(t)}function yt(t){return{bytes:t,offset:0,limit:t.length}}function an(t){let e=t.bytes,s=t.limit;return e.length===s?e:e.subarray(0,s)}function ut(t,e){if(t.offset+e>t.limit)throw new Error("Skip past limit");t.offset+=e}function Se(t){return t.offset>=t.limit}function Fe(t,e){let s=t.bytes,a=t.offset,n=t.limit,l=a+e;if(l>s.length){let i=new Uint8Array(l*2);i.set(s),t.bytes=i}return t.offset=l,l>n&&(t.limit=l),a}function wt(t,e){let s=t.offset;if(s+e>t.limit)throw new Error("Read past limit");return t.offset+=e,s}function Nt(t,e){let s=wt(t,e);return t.bytes.subarray(s,s+e)}function un(t,e){let s=Fe(t,e.length);t.bytes.set(e,s)}function de(t,e){let s=wt(t,e),a=String.fromCharCode,n=t.bytes,l="�",i="";for(let r=0;r<e;r++){let u=n[r+s],f,p,m,h;u&128?(u&224)===192?r+1>=e?i+=l:(f=n[r+s+1],(f&192)!==128?i+=l:(h=(u&31)<<6|f&63,h<128?i+=l:(i+=a(h),r++))):(u&240)==224?r+2>=e?i+=l:(f=n[r+s+1],p=n[r+s+2],((f|p<<8)&49344)!==32896?i+=l:(h=(u&15)<<12|(f&63)<<6|p&63,h<2048||h>=55296&&h<=57343?i+=l:(i+=a(h),r+=2))):(u&248)==240?r+3>=e?i+=l:(f=n[r+s+1],p=n[r+s+2],m=n[r+s+3],((f|p<<8|m<<16)&12632256)!==8421504?i+=l:(h=(u&7)<<18|(f&63)<<12|(p&63)<<6|m&63,h<65536||h>1114111?i+=l:(h-=65536,i+=a((h>>10)+55296,(h&1023)+56320),r+=3))):i+=l:i+=a(u)}return i}function et(t,e){let s=e.length,a=0;for(let i=0;i<s;i++){let r=e.charCodeAt(i);r>=55296&&r<=56319&&i+1<s&&(r=(r<<10)+e.charCodeAt(++i)-56613888),a+=r<128?1:r<2048?2:r<65536?3:4}H(t,a);let n=Fe(t,a),l=t.bytes;for(let i=0;i<s;i++){let r=e.charCodeAt(i);r>=55296&&r<=56319&&i+1<s&&(r=(r<<10)+e.charCodeAt(++i)-56613888),r<128?l[n++]=r:(r<2048?l[n++]=r>>6&31|192:(r<65536?l[n++]=r>>12&15|224:(l[n++]=r>>18&7|240,l[n++]=r>>12&63|128),l[n++]=r>>6&63|128),l[n++]=r&63|128)}}function cn(t,e){let s=Fe(t,e.limit),a=t.bytes,n=e.bytes;for(let l=0,i=e.limit;l<i;l++)a[l+s]=n[l]}function J(t){return t.bytes[wt(t,1)]}function Lt(t,e){let s=Fe(t,1);t.bytes[s]=e}function U(t){let e=0,s=0,a;do a=J(t),e<32&&(s|=(a&127)<<e),e+=7;while(a&128);return s}function H(t,e){for(e>>>=0;e>=128;)Lt(t,e&127|128),e>>>=7;Lt(t,e)}function ae(t,e){let s=0,a=0,n=0,l;return l=J(t),s=l&127,l&128&&(l=J(t),s|=(l&127)<<7,l&128&&(l=J(t),s|=(l&127)<<14,l&128&&(l=J(t),s|=(l&127)<<21,l&128&&(l=J(t),a=l&127,l&128&&(l=J(t),a|=(l&127)<<7,l&128&&(l=J(t),a|=(l&127)<<14,l&128&&(l=J(t),a|=(l&127)<<21,l&128&&(l=J(t),n=l&127,l&128&&(l=J(t),n|=(l&127)<<7))))))))),{low:s|a<<28,high:a>>>4|n<<24,unsigned:e}}function qe(t,e){let s=e.low>>>0,a=(e.low>>>28|e.high<<4)>>>0,n=e.high>>>24,l=n===0?a===0?s<16384?s<128?1:2:s<1<<21?3:4:a<16384?a<128?5:6:a<1<<21?7:8:n<128?9:10,i=Fe(t,l),r=t.bytes;switch(l){case 10:r[i+9]=n>>>7&1;case 9:r[i+8]=l!==9?n|128:n&127;case 8:r[i+7]=l!==8?a>>>21|128:a>>>21&127;case 7:r[i+6]=l!==7?a>>>14|128:a>>>14&127;case 6:r[i+5]=l!==6?a>>>7|128:a>>>7&127;case 5:r[i+4]=l!==5?a|128:a&127;case 4:r[i+3]=l!==4?s>>>21|128:s>>>21&127;case 3:r[i+2]=l!==3?s>>>14|128:s>>>14&127;case 2:r[i+1]=l!==2?s>>>7|128:s>>>7&127;case 1:r[i]=l!==1?s|128:s&127}}var dn=function(t,e){t.constructor==String?t=hn(t):o(t)?t=Array.prototype.slice.call(t,0):Array.isArray(t)||t.constructor===Uint8Array||(t=t.toString());for(var s=gn(t),a=8*t.length,n=1732584193,l=-271733879,i=-1732584194,r=271733878,u=0;u<s.length;u++)s[u]=(s[u]<<8|s[u]>>>24)&16711935|(s[u]<<24|s[u]>>>8)&4278255360;s[a>>>5]|=128<<a%32,s[(a+64>>>9<<4)+14]=a;for(var f=vn,p=fn,m=pn,h=mn,u=0;u<s.length;u+=16){var E=n,Y=l,C=i,_=r;n=f(n,l,i,r,s[u+0],7,-680876936),r=f(r,n,l,i,s[u+1],12,-389564586),i=f(i,r,n,l,s[u+2],17,606105819),l=f(l,i,r,n,s[u+3],22,-1044525330),n=f(n,l,i,r,s[u+4],7,-176418897),r=f(r,n,l,i,s[u+5],12,1200080426),i=f(i,r,n,l,s[u+6],17,-1473231341),l=f(l,i,r,n,s[u+7],22,-45705983),n=f(n,l,i,r,s[u+8],7,1770035416),r=f(r,n,l,i,s[u+9],12,-1958414417),i=f(i,r,n,l,s[u+10],17,-42063),l=f(l,i,r,n,s[u+11],22,-1990404162),n=f(n,l,i,r,s[u+12],7,1804603682),r=f(r,n,l,i,s[u+13],12,-40341101),i=f(i,r,n,l,s[u+14],17,-1502002290),l=f(l,i,r,n,s[u+15],22,1236535329),n=p(n,l,i,r,s[u+1],5,-165796510),r=p(r,n,l,i,s[u+6],9,-1069501632),i=p(i,r,n,l,s[u+11],14,643717713),l=p(l,i,r,n,s[u+0],20,-373897302),n=p(n,l,i,r,s[u+5],5,-701558691),r=p(r,n,l,i,s[u+10],9,38016083),i=p(i,r,n,l,s[u+15],14,-660478335),l=p(l,i,r,n,s[u+4],20,-405537848),n=p(n,l,i,r,s[u+9],5,568446438),r=p(r,n,l,i,s[u+14],9,-1019803690),i=p(i,r,n,l,s[u+3],14,-187363961),l=p(l,i,r,n,s[u+8],20,1163531501),n=p(n,l,i,r,s[u+13],5,-1444681467),r=p(r,n,l,i,s[u+2],9,-51403784),i=p(i,r,n,l,s[u+7],14,1735328473),l=p(l,i,r,n,s[u+12],20,-1926607734),n=m(n,l,i,r,s[u+5],4,-378558),r=m(r,n,l,i,s[u+8],11,-2022574463),i=m(i,r,n,l,s[u+11],16,1839030562),l=m(l,i,r,n,s[u+14],23,-35309556),n=m(n,l,i,r,s[u+1],4,-1530992060),r=m(r,n,l,i,s[u+4],11,1272893353),i=m(i,r,n,l,s[u+7],16,-155497632),l=m(l,i,r,n,s[u+10],23,-1094730640),n=m(n,l,i,r,s[u+13],4,681279174),r=m(r,n,l,i,s[u+0],11,-358537222),i=m(i,r,n,l,s[u+3],16,-722521979),l=m(l,i,r,n,s[u+6],23,76029189),n=m(n,l,i,r,s[u+9],4,-640364487),r=m(r,n,l,i,s[u+12],11,-421815835),i=m(i,r,n,l,s[u+15],16,530742520),l=m(l,i,r,n,s[u+2],23,-995338651),n=h(n,l,i,r,s[u+0],6,-198630844),r=h(r,n,l,i,s[u+7],10,1126891415),i=h(i,r,n,l,s[u+14],15,-1416354905),l=h(l,i,r,n,s[u+5],21,-57434055),n=h(n,l,i,r,s[u+12],6,1700485571),r=h(r,n,l,i,s[u+3],10,-1894986606),i=h(i,r,n,l,s[u+10],15,-1051523),l=h(l,i,r,n,s[u+1],21,-2054922799),n=h(n,l,i,r,s[u+8],6,1873313359),r=h(r,n,l,i,s[u+15],10,-30611744),i=h(i,r,n,l,s[u+6],15,-1560198380),l=h(l,i,r,n,s[u+13],21,1309151649),n=h(n,l,i,r,s[u+4],6,-145523070),r=h(r,n,l,i,s[u+11],10,-1120210379),i=h(i,r,n,l,s[u+2],15,718787259),l=h(l,i,r,n,s[u+9],21,-343485551),n=n+E>>>0,l=l+Y>>>0,i=i+C>>>0,r=r+_>>>0}return Dt([n,l,i,r])};const vn=function(t,e,s,a,n,l,i){var r=t+(e&s|~e&a)+(n>>>0)+i;return(r<<l|r>>>32-l)+e},fn=function(t,e,s,a,n,l,i){var r=t+(e&a|s&~a)+(n>>>0)+i;return(r<<l|r>>>32-l)+e},pn=function(t,e,s,a,n,l,i){var r=t+(e^s^a)+(n>>>0)+i;return(r<<l|r>>>32-l)+e},mn=function(t,e,s,a,n,l,i){var r=t+(s^(e|~a))+(n>>>0)+i;return(r<<l|r>>>32-l)+e},hn=function(t){for(var e=[],s=0;s<t.length;s++)e.push(255&t.charCodeAt(s));return e},gn=function(t){for(var e=[],s=0,a=0;s<t.length;s++,a+=8)e[a>>>5]|=t[s]<<24-a%32;return e},yn=function(t){for(var e=[],s=0;s<32*t.length;s+=8)e.push(t[s>>>5]>>>24-s%32&255);return e},Dt=function(t){if(t.constructor==Number)return 16711935&Rt(t,8)|4278255360&Rt(t,24);for(var e=0;e<t.length;e++)t[e]=Dt(t[e]);return t},Rt=function(t,e){return t<<e|t>>>32-e},wn=function(t){for(var e=[],s=0;s<t.length;s++)e.push((t[s]>>>4).toString(16)),e.push((15&t[s]).toString(16));return e.join("")},xn=(t,e)=>{const a=`,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=${e},device_platform=web,device_type=,ac=,identity=audience`.substring(1),n=dn(a),l=yn(n),i=wn(l);return window.byted_acrawler.frontierSign({"X-MS-STUB":i})["X-Bogus"]},kn=(t,e)=>{const s=k();let a,n=new ResizeObserver(l=>{clearTimeout(a),a=setTimeout(()=>{s.value.resize()},500)});return Ce(()=>{n.observe(t.value),e.canvas=t.value,s.value=new bn(e)}),tt(()=>{n.unobserve(t.value),clearTimeout(a)}),s};class bn{constructor(e){W(this,"canvas");W(this,"colors");W(this,"ctx");W(this,"isdraw");W(this,"lines");W(this,"textList");W(this,"fontSize");W(this,"font");W(this,"rows");W(this,"gap");W(this,"speed");W(this,"opacity");W(this,"opacityStr");this.isdraw=!1,this.textList=[],this.canvas=e.canvas,this.ctx=this.canvas.getContext("2d"),this.speed=e.speed||2,this.setFont(e.fontSize||16),this.setGap(e.gap||8),this.setRows(e.rows||4),this.setOpacity(e.opacity||100),this.setColors(e.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(e){this.opacity=e;const s=Math.floor(2.55*e).toString(16);this.opacityStr=s.length==1?"0"+s:s}setRows(e){this.rows=e}setSpeed(e){this.speed=e}setFont(e){this.ctx.textBaseline="top",this.fontSize=e,this.font=`${e}px sans-serif`}setGap(e){this.gap=e}setColors(e){this.colors=e}clean(){this.textList=[],this.isdraw=!1}destory(){this.lines=[],this.clean()}add(e){const s=this.getLine();if(s==-1)return;const a=Math.ceil(this.ctx.measureText(e).width),n=this.canvas.width+a;this.lines[s].width=n,this.textList.push({value:e,width:a,line:s,left:this.canvas.width,color:this.colors[Math.floor(Math.random()*this.colors.length)]}),!this.isdraw&&(this.isdraw=!0,this.draw())}getLine(){let e=-1,s=this.lines.length;for(;++e<s;)if(this.lines[e].width==this.canvas.width)return e;return-1}initRows(){this.lines=[];let e=-1;const s=this.gap+this.fontSize;for(;++e<this.rows;)this.lines.push({top:this.gap+s*e,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 e=-1,s=this.textList.length;const a=[];for(;++e<s;){const n=this.textList[e],l=n.left+n.width;if(l<=0)continue;this.ctx.fillStyle=n.color+this.opacityStr;const i=this.lines[n.line];i&&(this.ctx.fillText(n.value,n.left,this.lines[n.line].top),n.left-=this.speed,a.push(n),i.width=Math.max(l,this.canvas.width))}this.textList=a,a.length==0?this.isdraw=!1:requestAnimationFrame(this.draw.bind(this))}}const Cn={"w-full":"","h-full":"",flex:"","flex-col":"","lg:flex-row":"","box-border":"","md:pb-2":""},_n={"lg:grow-5":"",flex:"","flex-col":""},In={flex:"","p-2":"","pt-1":"","gap-2":"","text-lg":"","md:pr-3":""},Sn={"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":""},An={"aspect-ratio-video":""},Mn={"w-full":"","h-full":"","pos-absolute":"","top-0":"","z-1":"",flex:"","justify-center":"","items-center":"","text-6":""},Tn=["src"],En={key:0},On={class:"flex items-center gap-4 p-1"},jn={class:"flex items-center gap-4 p-1"},Ln={key:1,"h-0":"","w-0":""},Rn={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":""},Bn={flex:"","items-center":"","line-height-none":"","gap-4":"",b:"","b-y-solid":"","py-3":"","b-gray-7":"","px-4":""},Vn=["src"],Un={"grow-1":"","w-20":""},Pn={"h-4":"",truncate:""},zn={"h-4":"",flex:"","text-3":"","items-center":"","gap-1":""},Fn=["src"],$n={"pos-absolute":"","top-0":"","right-4":"","text-4":"",flex:"","flex-col":"","gap-3":""},Nn=["src"],Dn=["href"],Gn=["data-id","data-site","href"],Qn={"w-5":"","h-5":"","rounded-5":"",alt:""},Wn={flex:"","flex-col":"",b:"","b-solid":"","b-gray-6":"","rounded-2":"","px-2":""},Jn={flex:"","justify-between":"","items-center":"","mx-2":"","py-2":""},Yn={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},qn={flex:"","justify-between":"","items-center":"","mx-2":"","py-2":""},Hn={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Zn={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Kn={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Xn={flex:"","flex-col":"",b:"","b-solid":"","b-gray-6":"","rounded-2":"","px-2":""},el={flex:"","justify-between":"","items-center":"","mx-2":"","py-2":""},tl={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},ol={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},sl={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},nl={flex:"","flex-wrap":"",shadow:"",blur:"","bg-dark":"","p-2":"","box-border":"",b:"","b-solid":"","b-gray-7":"",style:{"box-shadow":"0 6px 15px 0 rgba(0, 0, 0, .5)"},rounded:""},ll=["data-color"],il={"p-3":"","bg-sm":"",flex:"","justify-between":"","items-center":""},rl=Q({__name:"play",setup(t){let e,s,a;const n=re({follow:!1,qn:0,line:0,notice:null,paused:!0,muted:!1,fullscreen:!1,webscreen:!1,showController:!0,pictureInPicture:!1}),l=mt(),i=k(),r=k(),u=k(),f=fo(),p=z(()=>f.value&&f.value.stream.length>0?f.value.stream.map(g=>g.name):[]),m=z(()=>p.value.length>0?f.value.stream[n.qn].lines.map(g=>g.name):[]),h=z(()=>m.value.length>0?f.value.stream[n.qn].lines[n.line].url:""),E=z(()=>j.map(g=>Object.values(g.follows)).flat().sort(g=>g.status?-1:0));oe(h,()=>{var g;if(h.value){if(n.flv){(g=n.flv)==null||g.switchURL(h.value,l.meta.site.id!="bilibili");return}if(Ye!=null&&Ye.isSupported("video")){const d=new Ye({media:r.value,seamlesslyReload:!0,isLive:!0,retryCount:0});return d.load(h.value),n.flv=d}return n.notice="不支持 flv",clearTimeout(s)}});const Y=()=>{u.value.scrollTop=0,Ae=0,u.value.innerHTML=""};let C,_=0,S=!0;const $e=k(),ee=kn($e,{gap:w.canvasGap,rows:w.canvasRows,speed:w.canvasSpeed,opacity:w.canvasOpacity,colors:w.canvasColorOpen?w.colors:["#ffffff"]}),ve=[];let fe;function se(){fe||(fe=setTimeout(()=>{let g=-1;const d=ve.length>5?5:ve.length;for(u.value.style.display="none";++g<d;)u.value.appendChild(ve[g]);u.value.style.display="block",ve.splice(0,5),S&&(u.value.scrollTop=u.value.scrollHeight),fe=void 0},200))}const N=(g,d)=>{var he;if(_++,w.blockOpen&&Et.value.length&&Et.value.some(Ee=>Ee.test(d))||(_%(w.sideClean||100)==0&&(u.value.innerHTML="",Ae=0),w.canvasOpen&&((he=ee.value)==null||he.add(d)),!we.value||!w.sideOpen))return;const I=document.createElement("div"),{sideColorOpen:A,sideFontsize:R,sideGap:D,colors:te}=w;I.style.margin=`${D}px 0`,I.style.fontSize=`${R}px`,A&&(I.style.color=te[Math.floor(Math.random()*te.length)]);const me=document.createElement("span");me.style.opacity="0.5",me.appendChild(document.createTextNode(g+":"));const ge=document.createElement("span");ge.appendChild(document.createTextNode(d)),I.appendChild(me),I.appendChild(ge),ve.push(I),se()};let Ae=0;const Me=()=>{if(u.value.scrollTop>=Ae)return Ae=u.value.scrollTop;Ae=u.value.scrollTop,S=!1,u.value.removeEventListener("scroll",Me)},Wt=()=>{S=!0,u.value.scrollTop=u.value.scrollHeight,u.value.addEventListener("scroll",Me,{passive:!1})};let ne;const xt=async()=>{var d;if(!f.value||C||!w.canvasOpen&&!w.sideOpen)return;let g=!0;if(f.value.siteId=="huya"){const I=(d=f.value)==null?void 0:d.ws;if(!I)return;C=new WebSocket(I),C.onopen=()=>{clearInterval(ne),N("系统","开始连接弹幕服务器"),u.value.addEventListener("scroll",Me),C==null||C.send(JSON.stringify({command:"subscribeNotice",data:["getMessageNotice"],reqId:Date.now().toString()})),ne=setInterval(()=>{C.send("ping")},45e3)},C.onmessage=A=>{if(g)return N("系统","弹幕服务器连接成功"),g=!1;const{sendNick:R,content:D}=JSON.parse(A.data).data;N(R,D)},C.onerror=()=>{clearInterval(ne),N("系统","弹幕服务器连接失败")}}else if(f.value.siteId=="douyu")C=new WebSocket("wss://danmuproxy.douyu.com:8506"),C.onopen=()=>{var I,A;clearInterval(ne),N("系统","开始连接弹幕服务器"),u.value.addEventListener("scroll",Me),C.send(Ne(`type@=loginreq/roomid@=${(I=f.value)==null?void 0:I.roomId}`)),C.send(Ne(`type@=joingroup/rid@=${(A=f.value)==null?void 0:A.roomId}/gid@=-9999`)),ne=setInterval(()=>{C.send(Ne("type@=mrkl/"))},45e3)},C.onmessage=async({data:I})=>{g&&(N("系统","弹幕服务器连接成功"),g=!1),(await I.text()).split(/type@=chatmsg\//).forEach(D=>{const te=D.match(/nn@=(.*)\/txt@=(.*)\/cid/);te!=null&&N(te[1],te[2])})},C.onerror=()=>{clearInterval(ne),N("系统","弹幕服务器连接失败")};else if(f.value.siteId=="douyin"){const I=f.value.ws.split(","),A=I[0],R=I[1],D=xn(A,R);let te=`wss://webcast5-ws-web-lf.douyin.com/webcast/im/push/v2/?room_id=${A}&compress=gzip&version_code=180800&webcast_sdk_version=1.0.14-beta.0&live_id=1&did_rule=3&user_unique_id=${R}&identity=audience&signature=${D}&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`;C=new WebSocket(te),C.binaryType="arraybuffer",C.onopen=()=>{clearInterval(ne),N("系统","开始连接弹幕服务器"),console.log(C),u.value.addEventListener("scroll",Me),ne=setInterval(()=>{(C==null?void 0:C.readyState)==1&&C.send(Ks({payloadType:"bh"}))},1e4)},C.onmessage=me=>{g&&(N("系统","弹幕服务器连接成功"),g=!1);const ge=en(new Uint8Array(me.data)),he=Qs(ge.payload),ie=Ws(new Uint8Array(he)).messagesList;if(!ie||ie.length==0)return;const Qe=ie.length;let ye=-1;for(;++ye<Qe;){if(ie[ye].method!="WebcastChatMessage")continue;const x=qs(ie[ye].payload);N(x.user.nickName,x.content)}},C.onerror=function(){console.log(this),clearInterval(ne),N("系统","弹幕服务器连接失败")}}},kt=new TextEncoder;function Ne(g){let d=kt.encode(g);const I=9+d.byteLength,A=[I,0,0,.1,I,0,0,0,177,2,0,0];d=kt.encode(g+"\0");const R=new Uint8Array(12+d.byteLength);return R.set(A),R.set(d,12),R.buffer}const nt=()=>{clearInterval(ne),C&&(C.onmessage=null,It=="douyu"?C.send(Ne("type@=logout")):C.close(),C=null,_=0,u.value&&De==l.fullPath&&N("系统","弹幕服务器断开连接"))};oe(f,()=>xt()),oe([()=>w.sideOpen,()=>w.canvasOpen],()=>{!w.sideOpen&&!w.canvasOpen&&nt(),C||xt()});const lt=()=>{const{site:g,id:d}=l.meta,I=l.meta.site.follows[d];I&&(f.value=I,n.follow=!0),clearInterval(ne),clearTimeout(s),n.notice="加载中...",at(()=>{N("系统","开始获取直播间信息")}),le(g.id,"getRoomDetail",{id:d}).then(A=>{if(f.value=A,n.follow&&Le(A),at(()=>N("系统","直播间信息获取成功")),!A.status)return n.notice="未开播!";document.title=f.value.title},A=>{n.notice=A,at(()=>N("系统","直播间信息获取失败"))}).finally(()=>clearTimeout(s))},Jt=()=>{if(!f.value)return;const{id:g}=l.meta.site;n.follow=n.follow?_o(g,f.value.roomId):Le(f.value)},it=()=>{!f.value||!f.value.status||(clearTimeout(e),e=setTimeout(()=>{n.paused?r.value.play():r.value.pause()},200))},bt=()=>{clearTimeout(e),n.fullscreen=!n.fullscreen,document.fullscreenElement?document.exitFullscreen():i.value.requestFullscreen()},pe=()=>{clearTimeout(a),n.showController=!0,a=setTimeout(()=>{var g,d;(g=r.value)!=null&&g.paused||!((d=r.value)!=null&&d.played.length)||(n.showController=!1)},3e3)},Yt=()=>{clearTimeout(e),n.webscreen=!n.webscreen,n.fullscreen&&(n.fullscreen=!1,document.exitFullscreen())},qt=()=>{n.paused=!1,pe()},Ht=()=>{n.paused=!0,pe()},Ct=g=>{if(h.value)switch(g.code){case"ArrowDown":return We(!1);case"ArrowUp":return We(!0);case"Space":return it()}},Zt=()=>{var g;clearTimeout(e),clearTimeout(a),clearTimeout(s),clearTimeout(fe),nt(),document.title="Lemon live",document.removeEventListener("keydown",Ct),n.pictureInPicture||(g=n.flv)==null||g.destroy()};lt();const _t=ht();let De=l.fullPath;Ce(()=>{i.value.style.filter=G.value==100?"":`brightness(${G.value/100})`,r.value.volume=q.value/100,n.muted=r.value.muted,r.value.addEventListener("canplay",()=>{n.notice=null}),Ze||(i.value.addEventListener("mousemove",pe),document.addEventListener("keydown",Ct)),document.pictureInPictureElement&&document.exitPictureInPicture(),r.value.addEventListener("leavepictureinpicture",()=>{var g;if(!/play/.test(l.path))return _t.push(De);if(l.fullPath==De)return n.pictureInPicture=!1;(g=n.flv)==null||g.destroy()})});let It=l.meta.site.id;To(g=>{const{siteid:d,id:I}=g.params,A=ke.findIndex(R=>R==d);return A==-1?{name:"404"}:(g.meta.site=j[A],g.meta.id=I,n.flv&&(n.flv.destroy(),n.flv=void 0),n.qn=0,n.line=0,n.follow=!1,f.value=void 0,!0)}),oe(()=>l.params,()=>{var g;clearTimeout(fe),nt(),Y(),(g=ee.value)==null||g.destory(),It=l.meta.site.id,De=l.fullPath,lt()}),tt(Zt);const Kt=()=>Promise.all(Xe(j,ct)),Xt=async g=>{g==1&&await Kt()},eo=()=>n.showController?it():pe(),to=()=>{n.pictureInPicture=!n.pictureInPicture,document.pictureInPictureElement?document.exitPictureInPicture():r.value.requestPictureInPicture()},oo=g=>{const d=g.target.dataset.color;if(!d)return;const I=w.colors.findIndex(A=>A==d);if(I==-1)return w.colors.push(d);w.colors.length!=1&&w.colors.splice(I,1)};oe(()=>w.colors,()=>{var g;return(g=ee.value)==null?void 0:g.setColors(w.colors)}),oe(()=>w.canvasSpeed,()=>{var g;return(g=ee.value)==null?void 0:g.setSpeed(w.canvasSpeed)}),oe(()=>w.canvasOpacity,()=>{var g;return(g=ee.value)==null?void 0:g.setOpacity(w.canvasOpacity)}),oe(()=>w.canvasColorOpen,()=>{var g;return(g=ee.value)==null?void 0:g.setColors(w.canvasColorOpen?w.colors:["#ffffff"])}),Ve(()=>{var g,d,I,A;(g=ee.value)==null||g.setGap(w.canvasGap),(d=ee.value)==null||d.setFont(w.canvasFontsize),(I=ee.value)==null||I.setRows(w.canvasRows),(A=ee.value)==null||A.resize()}),oe(q,()=>{pe(),clearTimeout(s),n.notice=`当前音量 ${q.value}%`,r.value.volume=q.value/100,be("volume",q.value),s=setTimeout(()=>n.notice=null,2e3)}),oe(G,()=>{pe(),clearTimeout(s),n.notice=`当前亮度 ${G.value}%`,i.value.style.filter=G.value==100?"":`brightness(${G.value/100})`,be("brightness",G.value),s=setTimeout(()=>n.notice=null,2e3)});let rt;const Ge=k(),so=g=>{clearTimeout(rt),rt=setTimeout(()=>{const d=Te("id",g.target,Ge.value);if(!d)return;const I=Te("site",g.target,Ge.value);_t.push(`/${I}/play/${d}`)},300)},no=g=>{var R;clearTimeout(rt);const d=Te("id",g.target,Ge.value);if(!d)return;const A=`/${Te("site",g.target,Ge.value)}/play/${d}`;(R=window.open(A,"_blank"))==null||R.location},Te=(g,d,I)=>{if(d==I)return null;const A=d.dataset[g];return A||Te(g,d.parentElement,I)},lo=()=>G.value=100;oe(()=>n.muted,()=>{pe(),clearTimeout(s),n.notice=n.muted?"已静音":"已开启声音",s=setTimeout(()=>n.notice=null,2e3)});const io=()=>{if(r.value.muted){r.value.muted=!1,n.muted=!1;return}r.value.muted=!0,n.muted=!0};return(g,d)=>{var he,Ee,ie,Qe,ye;const I=Gs,A=zs,R=ze,D=Vs,te=Rs,me=Pe,ge=vt("lazy");return y(),b("div",Cn,[c("div",_n,[c("div",In,[c("div",{"hover:text-amber":"",onClick:d[0]||(d[0]=(...x)=>g.$router.back&&g.$router.back(...x)),class:"i-ri-arrow-left-line"}),c("h1",Sn,T((he=v(f))==null?void 0:he.title),1),c("div",{onClick:d[1]||(d[1]=x=>we.value=!v(we)),hidden:"","lg:block":"",style:xe(v(we)?"transform:rotate(180deg)":"margin-right:1.5rem"),class:"i-ri-arrow-right-s-fill"},null,4)]),c("div",{ref_key:"player",ref:i,"md:rounded-6px":"","text-4":"","text-white":"",onContextmenu:d[19]||(d[19]=F(()=>{},["prevent"])),"bg-black":"","cursor-default":"",class:L({"cursor-none":!v(n).showController,"text-5":v(n).fullscreen,"text-5 !pos-fixed left-0 right-0 top-0 bottom-0 z-10 ":v(n).webscreen}),"pos-relative":"","w-full":"","overflow-hidden":"","select-none":"","h-full":"",onClick:eo,onDblclick:bt},[c("div",An,[c("video",{playsinline:"","webkit-playsinline":"","x5-video-player-type":"h5",autoplay:"",ref_key:"video",ref:r,"w-full":"","h-full":"","pos-absolute":"",onPlay:qt,onPause:Ht},null,544)]),B(c("div",Mn,[c("span",null,T(v(n).notice),1)],512),[[Z,v(n).notice]]),c("canvas",{ref_key:"canvas",ref:$e,"pos-absolute":"","top-0":"",width:"0",height:"0","w-full":"","h-full":"","z-1":""},null,512),B(c("div",{"pos-absolute":"","bottom-0":"","left-0":"","right-0":"","px-4":"","py-2":"","gap-3":"","z-20":"",flex:"","items-center":"",onClick:d[5]||(d[5]=F(()=>{},["stop"])),onDblclick:d[6]||(d[6]=F(()=>{},["stop"])),class:L({"py-3":v(n).fullscreen||v(n).webscreen}),"bg-black":"","bg-op-30":""},[c("div",{onClick:it,"hover:text-amber":"",class:L(v(n).paused?"i-ri-play-large-fill":"i-ri-pause-large-fill")},null,2),c("div",{"hover:text-amber":"",onClick:Jt,class:L(v(n).follow?"i-ri-heart-fill":"i-ri-heart-line")},null,2),c("div",{"hover:text-amber":"",onClick:lt,class:"i-ri-refresh-line"}),c("img",{"w-1.5em":"","cursor-pointer":"",onClick:d[2]||(d[2]=()=>v(w).canvasOpen=!v(w).canvasOpen),src:v(w).canvasOpen?v(Ot):v(jt)},null,8,Tn),d[33]||(d[33]=c("div",{grow:""},null,-1)),v(p).length?(y(),b("div",En,[M(I,{active:v(n).qn,"onUpdate:active":d[3]||(d[3]=x=>v(n).qn=x),list:v(p)},null,8,["active","list"]),M(I,{active:v(n).line,"onUpdate:active":d[4]||(d[4]=x=>v(n).line=x),list:v(m)},null,8,["active","list"]),v(Ze)?ue("",!0):(y(),b("div",{key:0,"ml-2":"","hover:text-amber":"",onClick:to,class:L(v(n).pictureInPicture?"i-ri-picture-in-picture-exit-line":"i-ri-picture-in-picture-2-line")},null,2))])):ue("",!0),c("div",{"hover:text-amber":"",onClick:Yt,class:"i-mdi-fit-to-screen"}),c("div",{"hover:text-amber":"",onClick:bt,class:L(v(n).fullscreen?"i-ri-fullscreen-exit-fill":"i-ri-fullscreen-fill")},null,2)],34),[[Z,v(n).showController]]),v(Ze)?B((y(),b("div",{key:0,class:L({"py-3":v(n).fullscreen||v(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:d[11]||(d[11]=F(()=>{},["stop"])),onDblclick:d[12]||(d[12]=F(()=>{},["stop"]))},[c("div",On,[c("div",{onClick:d[7]||(d[7]=x=>v(Mt)(!1)),class:"i-ri-sun-line"}),c("div",null,T(v(G)),1),c("div",{onClick:d[8]||(d[8]=x=>v(Mt)(!0)),class:"i-ri-sun-fill"})]),B(c("div",{"flex-1":"","w-10":"",truncate:"","text-center":""},T((Ee=v(f))==null?void 0:Ee.title),513),[[Z,v(n).fullscreen]]),c("div",jn,[c("div",{onClick:d[9]||(d[9]=x=>v(We)(!1)),class:"i-ri-volume-down-fill"}),c("div",null,T(v(q)),1),c("div",{onClick:d[10]||(d[10]=x=>v(We)(!0)),class:"i-ri-volume-up-fill"})])],34)),[[Z,v(n).showController]]):B((y(),b("div",Ln,[c("div",{onClick:d[14]||(d[14]=F(()=>{},["stop"])),onDblclick:d[15]||(d[15]=F(()=>{},["stop"])),"pos-absolute":"",class:"top-50% left-4 flex items-center flex-col",style:{transform:"translateY(-50%)"},"z-20":""},[c("div",null,T(v(G)),1),M(A,{value:v(G),"onUpdate:value":d[13]||(d[13]=x=>ce(G)?G.value=x:null),max:200,min:50},null,8,["value"]),c("div",{onClick:F(lo,["stop"]),class:"i-ri-sun-line"})],32),c("div",{onClick:d[17]||(d[17]=F(()=>{},["stop"])),onDblclick:d[18]||(d[18]=F(()=>{},["stop"])),"pos-absolute":"",class:"top-50% right-4 flex items-center flex-col",style:{transform:"translateY(-50%)"},"z-20":""},[je(T(v(q))+" ",1),M(A,{value:v(q),"onUpdate:value":d[16]||(d[16]=x=>ce(q)?q.value=x:null),max:100,min:0},null,8,["value"]),c("div",{onClick:F(io,["stop"]),class:L(v(n).muted?"i-ri-volume-mute-line":"i-ri-volume-down-line")},null,2)],32)],512)),[[Z,v(n).showController]])],34)]),B(c("div",Rn,[c("div",Bn,[c("img",{src:(ie=v(f))==null?void 0:ie.avatar,"w-8":"","h-8":"",alt:"","rounded-4":""},null,8,Vn),c("div",Un,[c("div",Pn,T((Qe=v(f))==null?void 0:Qe.nickname),1),c("div",zn,[c("img",{"w-4":"","h-4":"",src:g.$route.meta.site.icon},null,8,Fn),je(" "+T(g.$route.meta.site.name),1)])]),c("div",null,[d[34]||(d[34]=c("div",{"mx-1":"",class:"i-mdi-fire"},null,-1)),c("span",null,T((ye=v(f))==null?void 0:ye.online),1)])]),M(me,{grow:!0,onTabClick:Xt,class:"!h-[calc(100%-3.75rem)]"},{default:O(()=>[M(R,{title:"聊天","pos-relative":""},{default:O(()=>{var x;return[c("div",$n,[c("img",{"w-1.5em":"","cursor-pointer":"",onClick:d[20]||(d[20]=()=>v(w).sideOpen=!v(w).sideOpen),src:v(w).sideOpen?v(Ot):v(jt)},null,8,Nn),c("div",{"text-green-5":"",onClick:Y,class:"i-ri-delete-bin-3-line"}),c("a",{"text-green-5":"",href:(x=v(f))==null?void 0:x.url,target:"_blank"},d[35]||(d[35]=[c("div",{class:"i-ri-link"},null,-1)]),8,Dn),c("div",{onClick:Wt,"text-green-5":"",class:"i-ri-arrow-down-circle-line"})]),c("div",{ref_key:"dm",ref:u,"h-full":"","pl-2":"","box-border":"",class:"scrolly"},null,512)]}),_:1}),M(R,{title:"关注","box-border":"","px-4":""},{default:O(()=>[c("div",{onClick:F(so,["prevent"]),onDblclick:F(no,["prevent"])},[(y(!0),b($,null,X(v(E),x=>{var St,At;return y(),b("a",{"data-id":x.roomId,"data-site":x.siteId,class:L({"text-amber":((St=v(f))==null?void 0:St.siteId)==x.siteId&&((At=v(f))==null?void 0:At.roomId)==x.roomId}),key:`${x.siteId}/${x.roomId}`,href:`/${x.siteId}/play/${x.roomId}`,flex:"","items-center":"","gap-2":"","py-2":""},[B(c("img",Qn,null,512),[[ge,x.avatar]]),c("div",null,T(x.nickname),1),c("div",{"w-3":"","h-3":"","rounded-3":"",class:L([x.status?"bg-green":"bg-red"])},null,2),c("div",null,T(x.status?"直播中":"未开播"),1)],10,Gn)}),128))],32)]),_:1}),M(R,{title:"设置","px-2":""},{default:O(()=>[d[47]||(d[47]=c("div",{"p-3":"","bg-sm":""},"弹幕",-1)),c("div",Wn,[c("div",Jn,[d[36]||(d[36]=c("div",null,"文字大小",-1)),M(D,{value:v(w).canvasFontsize,"onUpdate:value":d[21]||(d[21]=x=>v(w).canvasFontsize=x),max:80,min:8,step:1},null,8,["value"])]),c("div",Yn,[d[37]||(d[37]=c("div",null,"上下间隔",-1)),M(D,{value:v(w).canvasGap,"onUpdate:value":d[22]||(d[22]=x=>v(w).canvasGap=x),max:80,min:1,step:1},null,8,["value"])]),c("div",qn,[d[38]||(d[38]=c("div",null,"最大行数",-1)),M(D,{value:v(w).canvasRows,"onUpdate:value":d[23]||(d[23]=x=>v(w).canvasRows=x),max:50,min:1,step:1},null,8,["value"])]),c("div",Hn,[d[39]||(d[39]=c("div",null,"弹幕速度",-1)),M(D,{value:v(w).canvasSpeed,"onUpdate:value":d[24]||(d[24]=x=>v(w).canvasSpeed=x),max:32,min:.5,step:.5},null,8,["value"])]),c("div",Zn,[d[40]||(d[40]=c("div",null,"弹幕透明",-1)),M(D,{value:v(w).canvasOpacity,"onUpdate:value":d[25]||(d[25]=x=>v(w).canvasOpacity=x),max:100,min:10,step:10},null,8,["value"])]),c("div",Kn,[d[41]||(d[41]=c("div",null,"彩色弹幕",-1)),M(te,{value:v(w).canvasColorOpen,"onUpdate:value":d[26]||(d[26]=x=>v(w).canvasColorOpen=x)},null,8,["value"])])]),d[48]||(d[48]=c("div",{"p-3":"","bg-sm":""},"聊天",-1)),c("div",Xn,[c("div",el,[d[42]||(d[42]=c("div",null,"文字大小",-1)),M(D,{value:v(w).sideFontsize,"onUpdate:value":d[27]||(d[27]=x=>v(w).sideFontsize=x),max:80,min:8,step:1},null,8,["value"])]),c("div",tl,[d[43]||(d[43]=c("div",null,"上下间隔",-1)),M(D,{value:v(w).sideGap,"onUpdate:value":d[28]||(d[28]=x=>v(w).sideGap=x),max:80,min:0,step:1},null,8,["value"])]),c("div",ol,[d[44]||(d[44]=c("div",null,"自动清屏",-1)),M(D,{value:v(w).sideClean,"onUpdate:value":d[29]||(d[29]=x=>v(w).sideClean=x),max:500,min:10,step:10},null,8,["value"])]),c("div",sl,[d[45]||(d[45]=c("div",null,"彩色消息",-1)),M(te,{value:v(w).sideColorOpen,"onUpdate:value":d[30]||(d[30]=x=>v(w).sideColorOpen=x)},null,8,["value"])])]),d[49]||(d[49]=c("div",{"p-3":"","bg-sm":""},"颜色",-1)),c("div",nl,[(y(!0),b($,null,X(v(So),x=>(y(),b("div",{onClick:oo},[c("div",{class:"w-4 h-4 rounded-2 m-2 shadow","box-border":"","data-color":x,"cursor-pointer":"",style:xe(`background:${x};${v(w).colors.includes(x)?"box-shadow:0 0 0px 2px white":""}`)},null,12,ll)]))),256))]),c("div",il,[d[46]||(d[46]=je("屏蔽 ")),M(te,{value:v(w).blockOpen,"onUpdate:value":d[31]||(d[31]=x=>v(w).blockOpen=x)},null,8,["value"])]),B(c("textarea",{"outline-none":"","w-full":"","onUpdate:modelValue":d[32]||(d[32]=x=>v(w).blockWords=x),"text-white":"",b:"","b-solid":"","b-gray-7":"","p-2":"","box-border":"",rows:"5","bg-dark":"",shadow:"","rounded-1":"",placeholder:"以空格分隔"},null,512),[[dt,v(w).blockWords,void 0,{trim:!0}]])]),_:1})]),_:1})],512),[[Z,v(we)]])])}}}),Gt=(t,e)=>{const s=t.__vccOpts||t;for(const[a,n]of e)s[a]=n;return s},al={},ul={"h-full":"","box-border":"","py-2":"",class:"scrolly"};function cl(t,e){return y(),b("div",ul,e[0]||(e[0]=[c("div",{"text-xl":"","p-4":""},"支持",-1),c("div",{"ml-4":""},[c("img",{"h-50":"","mr-5":"",src:"https://i0.hdslb.com/bfs/article/828b4686d0bcd7a427939b1f121f322898845873.png@1e_1c.webp"}),c("img",{"h-50":"",src:"https://i0.hdslb.com/bfs/article/d07b5e8cbae76f0fc38a8049c433d3d598845873.jpg@1e_1c.webp"})],-1)]))}const dl=Gt(al,[["render",cl]]),vl={},fl={"h-full":"",flex:"","justify-center":"","items-center":""};function pl(t,e){return y(),b("div",fl,e[0]||(e[0]=[c("div",{"text-center":"","text-8":"","line-height-8":""},[c("div",{"font-900":""},"404"),c("div",{"mt-4":""},"页面未找到")],-1)]))}const ml=Gt(vl,[["render",pl]]);async function Oe(t){const{siteid:e,id:s}=t.params,a=j.findIndex(n=>n.id==e);return a==-1?{name:"404"}:(t.meta.site=j[a],t.meta.id=s,t.meta.index=a,P.value=a,!0)}const hl=Ao({history:Mo(),routes:[{path:"/",redirect:()=>`/${ke[P.value]}`},{path:"/follow",component:js},{path:"/user",component:dl},{path:"/category",redirect:()=>`/${ke[P.value]}/category`},{path:"/search",redirect:()=>`/${ke[P.value]}/search`},{path:"/:siteid",component:Ls,beforeEnter:Oe},{path:"/:siteid/category",component:ps,beforeEnter:Oe},{path:"/:siteid/category/:id",component:es,beforeEnter:Oe},{path:"/:siteid/play/:id",component:rl,beforeEnter:Oe},{path:"/:siteid/search",component:xs,beforeEnter:Oe},{path:"/:pathMatch(.*)*",name:"404",component:ml}]}),gl={install(t){t.directive("lazy",{mounted(e,s){e.src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9Im5vbmUiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41IiBkPSJtMi4yNSAxNS43NWw1LjE1OS01LjE1OWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGw1LjE1OSA1LjE1OW0tMS41LTEuNWwxLjQwOS0xLjQwOWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGwyLjkwOSAyLjkwOW0tMTggMy43NWgxNi41YTEuNSAxLjUgMCAwIDAgMS41LTEuNVY2YTEuNSAxLjUgMCAwIDAtMS41LTEuNUgzLjc1QTEuNSAxLjUgMCAwIDAgMi4yNSA2djEyYTEuNSAxLjUgMCAwIDAgMS41IDEuNW0xMC41LTExLjI1aC4wMDh2LjAwOGgtLjAwOHptLjM3NSAwYS4zNzUuMzc1IDAgMSAxLS43NSAwYS4zNzUuMzc1IDAgMCAxIC43NSAwIi8+PC9zdmc+";const a=new IntersectionObserver(n=>{Ut(n,l=>{if(l.isIntersecting){const i=new Image;i.src=s.value,i.onload=()=>e.src=s.value,a.unobserve(l.target)}})});a.observe(e)}})}},Qt=uo(Lo);Qt.use(hl).use(gl);Qt.mount("#app");
1
+ var qa=Object.defineProperty;var Xa=(e,n,t)=>n in e?qa(e,n,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[n]=t;var he=(e,n,t)=>Xa(e,typeof n!="symbol"?n+"":n,t);(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))a(i);new MutationObserver(i=>{for(const l of i)if(l.type==="childList")for(const r of l.addedNodes)r.tagName==="LINK"&&r.rel==="modulepreload"&&a(r)}).observe(document,{childList:!0,subtree:!0});function t(i){const l={};return i.integrity&&(l.integrity=i.integrity),i.referrerPolicy&&(l.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?l.credentials="include":i.crossOrigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function a(i){if(i.ep)return;i.ep=!0;const l=t(i);fetch(i.href,l)}})();const el=Vue.createApp,v=Vue.createElementVNode,T=Vue.openBlock,U=Vue.createElementBlock,D=Vue.ref,je=Vue.reactive,Gt=Vue.watchEffect,J=Vue.computed,le=Vue.defineComponent,y=Vue.unref,Le=Vue.createCommentVNode,ge=Vue.renderList,oe=Vue.Fragment,Y=Vue.normalizeClass,xn=Vue.resolveComponent,K=Vue.withCtx,H=Vue.createVNode,ke=Vue.vShow,Q=Vue.withDirectives,Ut=Vue.resolveDynamicComponent,X=Vue.createBlock,tl=Vue.KeepAlive,wt=Vue.onMounted,we=Vue.watch,We=Vue.isRef,Z=Vue.toDisplayString,No=Vue.onActivated,En=Vue.resolveDirective,hi=Vue.vModelText,nl=Vue.withKeys,Rt=Vue.createTextVNode,q=Vue.withModifiers,dt=Vue.normalizeStyle,il=Vue.shallowRef,Fn=Vue.nextTick,In=Vue.onBeforeUnmount;Vue.h;const ol=Vue.onDeactivated,al=Vue.onUnmounted,Kt=Vue.useModel,Bt=Vue.mergeModels,ll=Vue.renderSlot,Zo=Vue.useSlots,sl=Vue.provide,rl=Vue.inject,cl=Vue.getCurrentInstance;var vn={exports:{}};vn.exports;var Di;function ul(){return Di||(Di=1,function(e){var n=function(){var t=String.fromCharCode,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",l={};function r(f,c){if(!l[f]){l[f]={};for(var u=0;u<f.length;u++)l[f][f.charAt(u)]=u}return l[f][c]}var s={compressToBase64:function(f){if(f==null)return"";var c=s._compress(f,6,function(u){return a.charAt(u)});switch(c.length%4){default:case 0:return c;case 1:return c+"===";case 2:return c+"==";case 3:return c+"="}},decompressFromBase64:function(f){return f==null?"":f==""?null:s._decompress(f.length,32,function(c){return r(a,f.charAt(c))})},compressToUTF16:function(f){return f==null?"":s._compress(f,15,function(c){return t(c+32)})+" "},decompressFromUTF16:function(f){return f==null?"":f==""?null:s._decompress(f.length,16384,function(c){return f.charCodeAt(c)-32})},compressToUint8Array:function(f){for(var c=s.compress(f),u=new Uint8Array(c.length*2),h=0,d=c.length;h<d;h++){var w=c.charCodeAt(h);u[h*2]=w>>>8,u[h*2+1]=w%256}return u},decompressFromUint8Array:function(f){if(f==null)return s.decompress(f);for(var c=new Array(f.length/2),u=0,h=c.length;u<h;u++)c[u]=f[u*2]*256+f[u*2+1];var d=[];return c.forEach(function(w){d.push(t(w))}),s.decompress(d.join(""))},compressToEncodedURIComponent:function(f){return f==null?"":s._compress(f,6,function(c){return i.charAt(c)})},decompressFromEncodedURIComponent:function(f){return f==null?"":f==""?null:(f=f.replace(/ /g,"+"),s._decompress(f.length,32,function(c){return r(i,f.charAt(c))}))},compress:function(f){return s._compress(f,16,function(c){return t(c)})},_compress:function(f,c,u){if(f==null)return"";var h,d,w={},I={},L="",E="",k="",M=2,S=3,b=2,x=[],p=0,_=0,g;for(g=0;g<f.length;g+=1)if(L=f.charAt(g),Object.prototype.hasOwnProperty.call(w,L)||(w[L]=S++,I[L]=!0),E=k+L,Object.prototype.hasOwnProperty.call(w,E))k=E;else{if(Object.prototype.hasOwnProperty.call(I,k)){if(k.charCodeAt(0)<256){for(h=0;h<b;h++)p=p<<1,_==c-1?(_=0,x.push(u(p)),p=0):_++;for(d=k.charCodeAt(0),h=0;h<8;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1}else{for(d=1,h=0;h<b;h++)p=p<<1|d,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=0;for(d=k.charCodeAt(0),h=0;h<16;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1}M--,M==0&&(M=Math.pow(2,b),b++),delete I[k]}else for(d=w[k],h=0;h<b;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1;M--,M==0&&(M=Math.pow(2,b),b++),w[E]=S++,k=String(L)}if(k!==""){if(Object.prototype.hasOwnProperty.call(I,k)){if(k.charCodeAt(0)<256){for(h=0;h<b;h++)p=p<<1,_==c-1?(_=0,x.push(u(p)),p=0):_++;for(d=k.charCodeAt(0),h=0;h<8;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1}else{for(d=1,h=0;h<b;h++)p=p<<1|d,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=0;for(d=k.charCodeAt(0),h=0;h<16;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1}M--,M==0&&(M=Math.pow(2,b),b++),delete I[k]}else for(d=w[k],h=0;h<b;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1;M--,M==0&&(M=Math.pow(2,b),b++)}for(d=2,h=0;h<b;h++)p=p<<1|d&1,_==c-1?(_=0,x.push(u(p)),p=0):_++,d=d>>1;for(;;)if(p=p<<1,_==c-1){x.push(u(p));break}else _++;return x.join("")},decompress:function(f){return f==null?"":f==""?null:s._decompress(f.length,32768,function(c){return f.charCodeAt(c)})},_decompress:function(f,c,u){var h=[],d=4,w=4,I=3,L="",E=[],k,M,S,b,x,p,_,g={val:u(0),position:c,index:1};for(k=0;k<3;k+=1)h[k]=k;for(S=0,x=Math.pow(2,2),p=1;p!=x;)b=g.val&g.position,g.position>>=1,g.position==0&&(g.position=c,g.val=u(g.index++)),S|=(b>0?1:0)*p,p<<=1;switch(S){case 0:for(S=0,x=Math.pow(2,8),p=1;p!=x;)b=g.val&g.position,g.position>>=1,g.position==0&&(g.position=c,g.val=u(g.index++)),S|=(b>0?1:0)*p,p<<=1;_=t(S);break;case 1:for(S=0,x=Math.pow(2,16),p=1;p!=x;)b=g.val&g.position,g.position>>=1,g.position==0&&(g.position=c,g.val=u(g.index++)),S|=(b>0?1:0)*p,p<<=1;_=t(S);break;case 2:return""}for(h[3]=_,M=_,E.push(_);;){if(g.index>f)return"";for(S=0,x=Math.pow(2,I),p=1;p!=x;)b=g.val&g.position,g.position>>=1,g.position==0&&(g.position=c,g.val=u(g.index++)),S|=(b>0?1:0)*p,p<<=1;switch(_=S){case 0:for(S=0,x=Math.pow(2,8),p=1;p!=x;)b=g.val&g.position,g.position>>=1,g.position==0&&(g.position=c,g.val=u(g.index++)),S|=(b>0?1:0)*p,p<<=1;h[w++]=t(S),_=w-1,d--;break;case 1:for(S=0,x=Math.pow(2,16),p=1;p!=x;)b=g.val&g.position,g.position>>=1,g.position==0&&(g.position=c,g.val=u(g.index++)),S|=(b>0?1:0)*p,p<<=1;h[w++]=t(S),_=w-1,d--;break;case 2:return E.join("")}if(d==0&&(d=Math.pow(2,I),I++),h[_])L=h[_];else if(_===w)L=M+M.charAt(0);else return null;E.push(L),h[w++]=M+L.charAt(0),d--,M=L,d==0&&(d=Math.pow(2,I),I++)}}};return s}();e!=null?e.exports=n:typeof angular<"u"&&angular!=null&&angular.module("LZString",[]).factory("LZString",function(){return n})}(vn)),vn.exports}var jo=ul(),Lo,Do,Uo,Bo,$o,Fo;const Ui=((Lo=typeof globalThis<"u"?globalThis:void 0)==null?void 0:Lo.crypto)||((Do=typeof global<"u"?global:void 0)==null?void 0:Do.crypto)||((Uo=typeof window<"u"?window:void 0)==null?void 0:Uo.crypto)||((Bo=typeof self<"u"?self:void 0)==null?void 0:Bo.crypto)||((Fo=($o=typeof frames<"u"?frames:void 0)==null?void 0:$o[0])==null?void 0:Fo.crypto);let ti;Ui?ti=e=>{const n=[];for(let t=0,a;t<e;t+=4)n.push(Ui.getRandomValues(new Uint32Array(1))[0]);return new Ye(n,e)}:ti=e=>{const n=[],t=a=>{let i=a,l=987654321;const r=4294967295;return()=>{l=36969*(l&65535)+(l>>16)&r,i=18e3*(i&65535)+(i>>16)&r;let s=(l<<16)+i&r;return s/=4294967296,s+=.5,s*(Math.random()>.5?1:-1)}};for(let a=0,i;a<e;a+=4){const l=t((i||Math.random())*4294967296);i=l()*987654071,n.push(l()*4294967296|0)}return new Ye(n,e)};class Tn{static create(...n){return new this(...n)}mixIn(n){return Object.assign(this,n)}clone(){const n=new this.constructor;return Object.assign(n,this),n}}class Ye extends Tn{constructor(n=[],t=n.length*4){super();let a=n;if(a instanceof ArrayBuffer&&(a=new Uint8Array(a)),(a instanceof Int8Array||a instanceof Uint8ClampedArray||a instanceof Int16Array||a instanceof Uint16Array||a instanceof Int32Array||a instanceof Uint32Array||a instanceof Float32Array||a instanceof Float64Array)&&(a=new Uint8Array(a.buffer,a.byteOffset,a.byteLength)),a instanceof Uint8Array){const i=a.byteLength,l=[];for(let r=0;r<i;r+=1)l[r>>>2]|=a[r]<<24-r%4*8;this.words=l,this.sigBytes=i}else this.words=n,this.sigBytes=t}toString(n=fl){return n.stringify(this)}concat(n){const t=this.words,a=n.words,i=this.sigBytes,l=n.sigBytes;if(this.clamp(),i%4)for(let r=0;r<l;r+=1){const s=a[r>>>2]>>>24-r%4*8&255;t[i+r>>>2]|=s<<24-(i+r)%4*8}else for(let r=0;r<l;r+=4)t[i+r>>>2]=a[r>>>2];return this.sigBytes+=l,this}clamp(){const{words:n,sigBytes:t}=this;n[t>>>2]&=4294967295<<32-t%4*8,n.length=Math.ceil(t/4)}clone(){const n=super.clone.call(this);return n.words=this.words.slice(0),n}}he(Ye,"random",ti);const fl={stringify(e){const{words:n,sigBytes:t}=e,a=[];for(let i=0;i<t;i+=1){const l=n[i>>>2]>>>24-i%4*8&255;a.push((l>>>4).toString(16)),a.push((l&15).toString(16))}return a.join("")},parse(e){const n=e.length,t=[];for(let a=0;a<n;a+=2)t[a>>>3]|=parseInt(e.substr(a,2),16)<<24-a%8*4;return new Ye(t,n/2)}},Bi={stringify(e){const{words:n,sigBytes:t}=e,a=[];for(let i=0;i<t;i+=1){const l=n[i>>>2]>>>24-i%4*8&255;a.push(String.fromCharCode(l))}return a.join("")},parse(e){const n=e.length,t=[];for(let a=0;a<n;a+=1)t[a>>>2]|=(e.charCodeAt(a)&255)<<24-a%4*8;return new Ye(t,n)}},Po={stringify(e){try{return decodeURIComponent(escape(Bi.stringify(e)))}catch{throw new Error("Malformed UTF-8 data")}},parse(e){return Bi.parse(unescape(encodeURIComponent(e)))}};class dl extends Tn{constructor(){super(),this._minBufferSize=0}reset(){this._data=new Ye,this._nDataBytes=0}_append(n){let t=n;typeof t=="string"&&(t=Po.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes}_process(n){let t;const{_data:a,blockSize:i}=this,l=a.words,r=a.sigBytes,s=i*4;let f=r/s;n?f=Math.ceil(f):f=Math.max((f|0)-this._minBufferSize,0);const c=f*i,u=Math.min(c*4,r);if(c){for(let h=0;h<c;h+=i)this._doProcessBlock(l,h);t=l.splice(0,c),a.sigBytes-=u}return new Ye(t,u)}clone(){const n=super.clone.call(this);return n._data=this._data.clone(),n}}class Ho extends dl{constructor(n){super(),this.blockSize=512/32,this.cfg=Object.assign(new Tn,n),this.reset()}static _createHelper(n){return(t,a)=>new n(a).finalize(t)}static _createHmacHelper(n){return(t,a)=>new hl(n,a).finalize(t)}reset(){super.reset.call(this),this._doReset()}update(n){return this._append(n),this._process(),this}finalize(n){return n&&this._append(n),this._doFinalize()}}class hl extends Tn{constructor(n,t){super();const a=new n;this._hasher=a;let i=t;typeof i=="string"&&(i=Po.parse(i));const l=a.blockSize,r=l*4;i.sigBytes>r&&(i=a.finalize(t)),i.clamp();const s=i.clone();this._oKey=s;const f=i.clone();this._iKey=f;const c=s.words,u=f.words;for(let h=0;h<l;h+=1)c[h]^=1549556828,u[h]^=909522486;s.sigBytes=r,f.sigBytes=r,this.reset()}reset(){const n=this._hasher;n.reset(),n.update(this._iKey)}update(n){return this._hasher.update(n),this}finalize(n){const t=this._hasher,a=t.finalize(n);return t.reset(),t.finalize(this._oKey.clone().concat(a))}}const z=[];for(let e=0;e<64;e+=1)z[e]=Math.abs(Math.sin(e+1))*4294967296|0;const re=(e,n,t,a,i,l,r)=>{const s=e+(n&t|~n&a)+i+r;return(s<<l|s>>>32-l)+n},ce=(e,n,t,a,i,l,r)=>{const s=e+(n&a|t&~a)+i+r;return(s<<l|s>>>32-l)+n},ue=(e,n,t,a,i,l,r)=>{const s=e+(n^t^a)+i+r;return(s<<l|s>>>32-l)+n},fe=(e,n,t,a,i,l,r)=>{const s=e+(t^(n|~a))+i+r;return(s<<l|s>>>32-l)+n};class _l extends Ho{_doReset(){this._hash=new Ye([1732584193,4023233417,2562383102,271733878])}_doProcessBlock(n,t){const a=n;for(let $=0;$<16;$+=1){const B=t+$,O=n[B];a[B]=(O<<8|O>>>24)&16711935|(O<<24|O>>>8)&4278255360}const i=this._hash.words,l=a[t+0],r=a[t+1],s=a[t+2],f=a[t+3],c=a[t+4],u=a[t+5],h=a[t+6],d=a[t+7],w=a[t+8],I=a[t+9],L=a[t+10],E=a[t+11],k=a[t+12],M=a[t+13],S=a[t+14],b=a[t+15];let x=i[0],p=i[1],_=i[2],g=i[3];x=re(x,p,_,g,l,7,z[0]),g=re(g,x,p,_,r,12,z[1]),_=re(_,g,x,p,s,17,z[2]),p=re(p,_,g,x,f,22,z[3]),x=re(x,p,_,g,c,7,z[4]),g=re(g,x,p,_,u,12,z[5]),_=re(_,g,x,p,h,17,z[6]),p=re(p,_,g,x,d,22,z[7]),x=re(x,p,_,g,w,7,z[8]),g=re(g,x,p,_,I,12,z[9]),_=re(_,g,x,p,L,17,z[10]),p=re(p,_,g,x,E,22,z[11]),x=re(x,p,_,g,k,7,z[12]),g=re(g,x,p,_,M,12,z[13]),_=re(_,g,x,p,S,17,z[14]),p=re(p,_,g,x,b,22,z[15]),x=ce(x,p,_,g,r,5,z[16]),g=ce(g,x,p,_,h,9,z[17]),_=ce(_,g,x,p,E,14,z[18]),p=ce(p,_,g,x,l,20,z[19]),x=ce(x,p,_,g,u,5,z[20]),g=ce(g,x,p,_,L,9,z[21]),_=ce(_,g,x,p,b,14,z[22]),p=ce(p,_,g,x,c,20,z[23]),x=ce(x,p,_,g,I,5,z[24]),g=ce(g,x,p,_,S,9,z[25]),_=ce(_,g,x,p,f,14,z[26]),p=ce(p,_,g,x,w,20,z[27]),x=ce(x,p,_,g,M,5,z[28]),g=ce(g,x,p,_,s,9,z[29]),_=ce(_,g,x,p,d,14,z[30]),p=ce(p,_,g,x,k,20,z[31]),x=ue(x,p,_,g,u,4,z[32]),g=ue(g,x,p,_,w,11,z[33]),_=ue(_,g,x,p,E,16,z[34]),p=ue(p,_,g,x,S,23,z[35]),x=ue(x,p,_,g,r,4,z[36]),g=ue(g,x,p,_,c,11,z[37]),_=ue(_,g,x,p,d,16,z[38]),p=ue(p,_,g,x,L,23,z[39]),x=ue(x,p,_,g,M,4,z[40]),g=ue(g,x,p,_,l,11,z[41]),_=ue(_,g,x,p,f,16,z[42]),p=ue(p,_,g,x,h,23,z[43]),x=ue(x,p,_,g,I,4,z[44]),g=ue(g,x,p,_,k,11,z[45]),_=ue(_,g,x,p,b,16,z[46]),p=ue(p,_,g,x,s,23,z[47]),x=fe(x,p,_,g,l,6,z[48]),g=fe(g,x,p,_,d,10,z[49]),_=fe(_,g,x,p,S,15,z[50]),p=fe(p,_,g,x,u,21,z[51]),x=fe(x,p,_,g,k,6,z[52]),g=fe(g,x,p,_,f,10,z[53]),_=fe(_,g,x,p,L,15,z[54]),p=fe(p,_,g,x,r,21,z[55]),x=fe(x,p,_,g,w,6,z[56]),g=fe(g,x,p,_,b,10,z[57]),_=fe(_,g,x,p,h,15,z[58]),p=fe(p,_,g,x,M,21,z[59]),x=fe(x,p,_,g,c,6,z[60]),g=fe(g,x,p,_,E,10,z[61]),_=fe(_,g,x,p,s,15,z[62]),p=fe(p,_,g,x,I,21,z[63]),i[0]=i[0]+x|0,i[1]=i[1]+p|0,i[2]=i[2]+_|0,i[3]=i[3]+g|0}_doFinalize(){const n=this._data,t=n.words,a=this._nDataBytes*8,i=n.sigBytes*8;t[i>>>5]|=128<<24-i%32;const l=Math.floor(a/4294967296),r=a;t[(i+64>>>9<<4)+15]=(l<<8|l>>>24)&16711935|(l<<24|l>>>8)&4278255360,t[(i+64>>>9<<4)+14]=(r<<8|r>>>24)&16711935|(r<<24|r>>>8)&4278255360,n.sigBytes=(t.length+1)*4,this._process();const s=this._hash,f=s.words;for(let c=0;c<4;c+=1){const u=f[c];f[c]=(u<<8|u>>>24)&16711935|(u<<24|u>>>8)&4278255360}return s}clone(){const n=super.clone.call(this);return n._hash=this._hash.clone(),n}}const $i=Ho._createHelper(_l),yn=(e,n)=>{let t=-1;const a=e.length,i=new Array(a);for(;++t<a;)i[t]=n(e[t]);return i},Vo=(e,n)=>{let t=-1;const a=e.length;for(;++t<a;)n(e[t])},pl=e=>{if(e.scrollTop>0)return!0;e.scrollTop=1;const n=!!e.scrollTop;return e.scrollTop=0,n},vl=async(e,n,t)=>{const a=[],i=[];for(const l of e){const r=Promise.resolve().then(()=>t(l));if(a.push(r),n<=e.length){const s=r.then(()=>i.splice(i.indexOf(s),1));i.push(s),i.length>=n&&await Promise.race(i)}}return Promise.all(a)},Fi=e=>{let n="",t=-1,a=13;for(;++t<a;)n+=Math.random()*10|0;const i=(Date.now()%1e10*1e3+(1e3*Math.random()|0)%4294967295).toString(),l=new URLSearchParams(e.code),r=l.get("fs"),s=(Date.now()/1e3|21600).toString(16),f=(Date.now()+Number(n)).toString(),c=atob(l.get("fm")).split("_")[0],u=$i(`${f}|tars_mp|102`).toString();return`&wsSecret=${$i([c,n,e.name,u,s].join("_")).toString()}&uuid=${i}&wsTime=${s}&uid=${n}&seqid=${f}&fs=${r}&ctype=tars_mp&t=102&ver=1&sv=2401310321`},gl="https://lemonlive.deno.dev/api/",Go="https://lemonlivesync.deno.dev/",De=(e,n,t)=>(e=="douyin"&&(t?t.cookie=Se[e]:t={cookie:Se[e]}),_i(`${gl}${e}/${n}${t?"?"+new URLSearchParams(t).toString():""}`)),ni=async e=>{const n=Object.keys(e.follows);if(!n.length)return Promise.resolve(!1);if(e.id=="douyin"){(await vl(n,4,a=>De("douyin","getLiveStatus",{id:a}))).forEach((a,i)=>e.follows[n[i]].status=a[n[i]].status);return}await De(e.id,"getLiveStatus",{id:n.join(",")}).then(t=>Object.keys(t).forEach(a=>{e.follows[a].status=t[a].status}))},ml=e=>_i(`${Go}sync`,{method:"POST",body:jo.compressToBase64(JSON.stringify(e))}),wl=e=>_i(`${Go}sync/${e}`),_i=(e,n)=>fetch(e,n).then(async t=>{let a=await t.text();return a=JSON.parse(jo.decompressFromBase64(a)),a.code!=200?Promise.reject(a.msg):a.data},t=>{Promise.reject("网络异常!")});D(!0);const xl={huya:"虎牙",bilibili:"哔哩",douyu:"斗鱼",douyin:"抖音"},W=[{name:"虎牙直播",icon:"https://www.huya.com/favicon.ico",id:"huya",categories:D([]),categoryActive:D(0),recommend:{page:1,hasMore:!0,list:D([])},search:{page:1,hasMore:!0,list:D([])},follows:je(sn("huya"))},{name:"斗鱼直播",icon:"https://www.douyu.com/favicon.ico",id:"douyu",categories:D([]),categoryActive:D(0),recommend:{page:1,hasMore:!0,list:D([])},search:{page:1,hasMore:!0,list:D([])},follows:je(sn("douyu"))},{name:"抖音直播",icon:"https://www.douyin.com/favicon.ico",id:"douyin",categories:D([]),categoryActive:D(0),recommend:{page:1,hasMore:!0,list:D([])},search:{page:1,hasMore:!0,list:D([])},follows:je(sn("douyin"))},{name:"哔哩直播",icon:"https://www.bilibili.com/favicon.ico",id:"bilibili",categories:D([]),categoryActive:D(0),recommend:{page:1,hasMore:!0,list:D([])},search:{page:1,hasMore:!0,list:D([])},follows:je(sn("bilibili"))}],ht=["huya","douyu","douyin","bilibili"],xe=D(xt("volume",100)),de=D(xt("brightness",100)),ln=e=>{xe.value=e?Math.min(100,xe.value+5):Math.max(0,xe.value-5)},Ni=e=>{de.value=e?Math.min(200,de.value+10):Math.max(50,de.value-10)};function sn(e){const n=localStorage.getItem("follows-"+e);return n?JSON.parse(n):{}}function Mt(e){const n=W.find(t=>t.id==e.siteId);return e.siteId=n.id,n.follows[e.roomId]={...e,stream:void 0,ws:void 0},localStorage.setItem("follows-"+e.siteId,JSON.stringify(n.follows)),Reflect.has(n.follows,e.roomId)}function ii(e,n){const t=W.find(a=>a.id==e);return delete t.follows[n],localStorage.setItem("follows-"+e,JSON.stringify(t.follows)),Reflect.has(t.follows,n)}function yl(){W.forEach(e=>{for(const n in e.follows)delete e.follows[n];localStorage.removeItem("follows-"+e.id)})}async function Zi(e,n){const t=e.categories;t.value.length||(t.value=await De(e.id,"getCategories"));for(const a of t.value)for(const i of a.list)if(i.cid==n)return i;return null}const C=je(xt("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:""}));Gt(()=>{pt("dm-settings",C)});function xt(e,n){const t=localStorage.getItem(e);return t?JSON.parse(t):n}function pt(e,n){localStorage.setItem(e,JSON.stringify(n))}const bl=["#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"],ji=J(()=>C.blockWords.length==0?[]:C.blockWords.split(" ").map(e=>new RegExp(e))),Se=je(xt("cookies",{}));Gt(()=>pt("cookies",Se));const ie=D(0),ft=D(xt("show-chat",!0)),gn=D(xt("show-aside",!0));Gt(()=>pt("show-chat",ft.value));Gt(()=>pt("show-aside",gn.value));const kl=VueRouter.createRouter,Sl=VueRouter.createWebHistory,pi=VueRouter.useRoute,Cn=VueRouter.useRouter,Al=VueRouter.onBeforeRouteUpdate,El={key:0,src:"https://live.douyin.com","pos-absolute":"",width:"0",height:"0","op-0":"","b-0":"",style:{"z-index":"-10"}},Il={"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":""},Tl={"h-full":"",class:"scrolly","md:px-3":""},Cl=le({__name:"App",setup(e){const n=[{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"}],t=D(!0);wt(()=>{document.querySelector("main").style.height=`calc(${window.innerHeight}px - 3.5rem)`,setTimeout(()=>t.value=!1,5e3)});const a=pi();return we(a,()=>{const i=a.params.siteid;if(i==null)return;const l=ht.findIndex(r=>r==i);l!=-1&&(ie.value=l)}),(i,l)=>{const r=xn("router-link"),s=xn("router-view");return T(),U(oe,null,[y(t)?(T(),U("iframe",El)):Le("",!0),Q(v("div",Il,[(T(),U(oe,null,ge(n,f=>H(r,{to:f.link,"hover:text-amber":"","rounded-2":"","py-2":"","px-4":"","m-2":"",class:Y({"text-amber":i.$route.path==f.link})},{default:K(()=>[v("div",{class:Y(f.icon)},null,2)]),_:2},1032,["to","class"])),64))],512),[[ke,y(gn)]]),v("main",{"mx-2":"","md:mx-0":"",class:Y(["md:!h-100vh",{"md:ml-17.5":y(gn),"!h-100vh":!y(gn)}]),"pt-2":"","box-border":""},[v("div",Tl,[H(s,null,{default:K(({Component:f})=>[(T(),X(tl,{exclude:["play"]},[(T(),X(Ut(f)))],1024))]),_:1})])],2)],64)}}}),zl=e=>{const n=D(e);return[n,a=>n.value=a]},Rl=/scroll|auto|overlay/i;function Ml(e){return e.tagName!=="HTML"&&e.tagName!=="BODY"&&e.nodeType===1}function Ol(e,n=document.body){let t=e;for(;t&&t!==n&&Ml(t);){const{overflowY:a}=window.getComputedStyle(t);if(Rl.test(a))return t;t=t.parentNode}return n}function Ll(e,n=document.body){const t=D();return wt(()=>{e.value&&(t.value=Ol(e.value,n))}),t}const Dl={key:0,"text-center":""},Ul={key:1,"text-center":""},zn=le({__name:"list",props:{finshedText:{default:"没有更多了"},errorText:{default:"加载失败,点击重新加载"},immediate:{type:Boolean,default:!0},offset:{default:50}},emits:["load","refresh"],setup(e,{emit:n}){const t=e,a=D(0),[i,l]=zl("normal"),r=D(),s=Ll(r),f=n,c=()=>{if(a.value=s.value.scrollTop,i.value!="normal")return;s.value.scrollHeight-s.value.clientHeight-s.value.scrollTop<t.offset&&d()};wt(()=>{t.immediate&&d(),s.value.addEventListener("scroll",c,{passive:!0})}),No(()=>{s.value.scrollTop=a.value,s.value.addEventListener("scroll",c)});const u=()=>{s.value.removeEventListener("scroll",c)};ol(u),In(u);let h;const d=()=>{l("loading"),f("load",l),clearTimeout(h),h=setTimeout(()=>{pl(s.value)||f("load",l)},2e3)};return(w,I)=>(T(),U("div",{ref_key:"root",ref:r,"h-full":"","select-none":""},[ll(w.$slots,"default"),y(i)=="loading"?(T(),U("div",Dl,"加载中...")):y(i)=="finshed"?(T(),U("div",Ul,Z(t.finshedText),1)):y(i)=="loaderror"?(T(),U("div",{key:2,"text-center":"","cursor-pointer":"",onClick:d},Z(t.errorText),1)):Le("",!0)],512))}}),Bl=["data-id","data-site","href"],$l={"pos-relative":"","text-fuchsia-5":"","rounded-t-2":"","w-full":"","aspect-video":""},Fl={block:"","mx-auto":"","h-full":"","rounded-2":"","select-none":""},Nl={"pos-absolute":"","bottom-0":"","right-0":"","px-2":"","py-1":"","rounded-tl-2":"","bg-dark-6":""},Zl={"line-height-none":"","pos-absolute":"","top-0":"","right-0":"","px-1":"","py-1":"","rounded-tr-1":"","rounded-bl-2":"","bg-dark-6":""},jl={key:0,"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":""},Pl={"px-2":"","text-truncate":"","leading-normal":""},Hl={"px-2":"","text-truncate":"","leading-normal":"","pb-2":""},vi=le({__name:"rooms",props:{list:{}},setup(e){let n;const t=Cn(),a=D(),i=s=>{clearTimeout(n),n=setTimeout(()=>{const f=r("id",s.target,a.value);if(!f)return;const c=r("site",s.target,a.value);t.push(`/${c}/play/${f}`)},300)},l=s=>{var h;clearTimeout(n);const f=r("id",s.target,a.value);if(!f)return;const u=`/${r("site",s.target,a.value)}/play/${f}`;(h=window.open(u,"_blank"))==null||h.location},r=(s,f,c)=>{if(f==c)return null;const u=f.dataset[s];return u||r(s,f.parentElement,c)};return(s,f)=>{const c=En("lazy");return s.list.value.length>0?(T(),U("div",{key:0,ref_key:"root",ref:a,grid:"","gap-4":"","p-2":"","justify-evenly":"","cursor-pointer":"","select-none":"","grid-cols-2":"","md:grid-cols-3":"","xl:grid-cols-4":"",class:"2xl:grid-cols-5",onClick:q(i,["prevent"]),onDblclick:q(l,["prevent"])},[(T(!0),U(oe,null,ge(s.list.value,u=>(T(),U("a",{"data-id":u.roomId,"data-site":u.siteId,href:`/${u.siteId}/play/${u.roomId}`,key:`${u.siteId}-${u.roomId}`,shadow:"","rounded-2":"","b-2px":"","b-solid":"","b-transparent":"","hover:b-amber":"","overflow-hidden":""},[v("div",$l,[Q(v("img",Fl,null,512),[[c,u.cover]]),v("div",Nl,Z(u.category),1),v("div",Zl,[f[0]||(f[0]=v("div",{class:"i-mdi-fire"},null,-1)),v("span",null,Z(u.online),1)]),u.status?Le("",!0):(T(),U("div",jl," 未开播 "))]),v("div",Pl,Z(u.title),1),v("div",Hl,Z(u.nickname),1)],8,Bl))),128))],544)):Le("",!0)}}}),Vl={"h-full":""},Gl={flex:"","py-1":"","px-2":"","text-lg":"","gap-2":""},Kl={grow:"","text-center":""},Wl={"hover:text-amber":""},Yl={key:0,class:"h-[calc(100%-3.25rem)] scrolly"},Ql=le({__name:"categoryRooms",setup(e){const n=pi(),t=D(""),a=D(),i={list:D([]),page:1,hasMore:!0},l=c=>{const{site:u,id:h}=n.meta;De(u.id,"getCategoryRooms",{id:h,pid:a.value,page:i.page}).then(d=>{if(i.list.value=i.list.value.concat(d.list),i.hasMore=d.hasMore,Se[u.id]||(Se[u.id]=d.cookie),!d.hasMore)return c("finshed");i.page++,c("normal")},d=>{t.value=d,c("loaderror")})},r=D(!1),s=()=>{document.querySelector("#goTop").click(),r.value=!0;const{site:c,id:u}=n.meta;De(c.id,"getCategoryRooms",{id:u,pid:a.value,page:i.page}).then(h=>{i.list.value=h.list,i.hasMore=h.hasMore,i.page++,Se[c.id]||(Se[c.id]=h.cookie)},h=>{t.value=h}).finally(()=>r.value=!1)};let f=n.fullPath;return Zi(n.meta.site,n.meta.id).then(c=>{t.value=(c==null?void 0:c.name)||null,a.value=c==null?void 0:c.pid}),No(function(){f!=n.fullPath&&(f=n.fullPath,Zi(n.meta.site,n.meta.id).then(c=>{t.value=(c==null?void 0:c.name)||null,a.value=c==null?void 0:c.pid}),i.list.value=[],i.page=1,i.hasMore=!0)}),(c,u)=>{var w;const h=vi,d=zn;return T(),U("div",Vl,[v("div",Gl,[v("div",{"hover:text-amber":"",onClick:u[0]||(u[0]=(...I)=>c.$router.back&&c.$router.back(...I)),class:"i-ri-arrow-left-line"}),v("div",Kl,[v("span",Wl,Z(`${(w=y(n).meta.site)==null?void 0:w.name} ${y(t)==null?"分区不存在":y(t)==""?"加载中":y(t)}`),1)]),v("div",{"mr-7":"","md:mr-24":"","hover:text-amber":"",onClick:s,class:Y(["i-ri-refresh-line",{"animate-spin":y(r)}])},null,2)]),y(t)?(T(),U("div",Yl,[(T(),X(d,{key:y(f),onLoad:l},{default:K(()=>[H(h,{list:i.list},null,8,["list"])]),_:1}))])):Le("",!0)])}}}),Ko=Symbol("tabs"),Jl=(e,n)=>{const t=je([]);return sl(e,Object.assign({link:l=>{l.proxy&&t.push(l.proxy)},unlink:l=>{const r=t.indexOf(l.proxy);t.splice(r,1)},children:t},n)),t},Wo=e=>{const n=rl(e);if(n==null)return{parent:n,index:D(-1)};const t=cl(),{link:a,unlink:i,children:l}=n;a(t),al(()=>i(t));const r=J(()=>l.indexOf(t.proxy));return{parent:n,children:l,index:r}},ql={class:"h-full","box-border":""},Xl={"w-full":"","box-border":"","text-sm":"","sm:text-base":""},es=["onClick"],ts={class:"h-[calc(100%-2rem)] scrolly","box-border":"","pt-1":""},Wt=le({__name:"tabs",props:Bt({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:Bt(["tabClick"],["update:active"]),setup(e,{emit:n}){const t=Kt(e,"active"),a=e,i=n,l=f=>{t.value=f,i("tabClick",f)},r=Jl(Ko,{active:t,props:a}),s=J(()=>yn(r,f=>f.title));return(f,c)=>{const u=xn("router-link");return T(),U("div",ql,[v("div",Xl,[v("div",{flex:"",p1:"","sm:gap-1":"","text-center":"","h-8":"","box-border":"","lg:justify-center":"",class:Y([[y(r).length>5||f.grow?"":f.justify],"scrollx"])},[a.link?(T(!0),U(oe,{key:0},ge(y(s),(h,d)=>(T(),X(u,{"px-1":"","sm:px-2":"","box-border":"","shrink-0":"",rounded:"","py-1":"","line-height-none":"","text-centercursor-pointer":"","hover:text-amber":"","cursor-pointer":"",class:Y({"text-amber":t.value==d,grow:f.grow}),to:y(r)[d].href},{default:K(()=>[Rt(Z(h),1)]),_:2},1032,["class","to"]))),256)):(T(!0),U(oe,{key:1},ge(y(s),(h,d)=>(T(),U("a",{"px-1":"","sm:px-2":"","box-border":"","shrink-0":"",rounded:"","py-1":"","line-height-none":"","text-centercursor-pointer":"","hover:text-amber":"","cursor-pointer":"",class:Y({"text-amber":t.value==d,grow:f.grow}),onClick:w=>l(d)},Z(h),11,es))),256))],2)]),v("div",ts,[(T(),X(Ut(f.$slots.default)))])])}}}),ns=Symbol("swipe"),is={"w-full":"","h-full":"","shrink-0":"","pos-relative":""},os=le({__name:"swipeItem",emits:["inited"],setup(e,{emit:n}){const t=D(!1),{parent:a,children:i,index:l}=Wo(ns),r=Zo(),s=n,f=J(()=>(a==null?void 0:a.active.value)==l.value?(t.value||(t.value=!0,s("inited",l.value)),!0):l.value==(a.active.value==0?i.length-1:a.active.value-1)||l.value==(a.active.value==i.length-1?0:a.active.value+1)),c=J(()=>f.value||t.value||!(a!=null&&a.props.lazy)?r.default:null);return(u,h)=>Q((T(),U("div",is,[(T(),X(Ut(y(c))))],512)),[[ke,y(f)]])}}),as={"h-full":"","w-full":"","shrink-0":"",class:"scrolly"},Yt=le({__name:"tab",props:{title:{},href:{}},emits:["inited"],setup(e,{expose:n,emit:t}){const a=e,i=D(!1),l=Zo(),{parent:r,index:s,children:f}=Wo(Ko),c=t,u=J(()=>(r==null?void 0:r.active.value)==s.value?(i.value||(i.value=!0,c("inited",s.value)),!0):(r==null?void 0:r.props.swipeable)&&(s.value==(r.active.value==0?f.length-1:r.active.value-1)||s.value==(r.active.value==f.length-1?0:r.active.value+1))),h=J(()=>u.value||r!=null&&r.props.swipeable||i.value||!(r!=null&&r.props.lazy)?l.default:null);return n({title:a.title}),(d,w)=>{var L,E;const I=os;return Q((T(),U("div",as,[(L=y(r))!=null&&L.props.swipeable?(T(),X(I,{key:0},{default:K(()=>[(T(),X(Ut(y(h))))]),_:1})):(T(),X(Ut(y(h)),{key:1}))],512)),[[ke,y(u)||((E=y(r))==null?void 0:E.props.swipeable)]])}}}),ls={key:0,"text-center":""},ss={"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":"",lass:"2xl:grid-cols-18"},rs={"w-full":"","aspect-ratio-square":"",rounded:""},cs={"w-full":"","text-truncate":"","text-xs":"","md:text-sm":"","text-center":""},us=le({__name:"category",setup(e){const n=J(()=>W[ie.value].id),t=D(),a=i=>{W[i].categories.value.length||(t.value="加载中...",De(n.value,"getCategories").then(l=>{t.value=null,W[i].categories.value=l},l=>t.value=l))};return(i,l)=>{const r=xn("router-link"),s=Yt,f=Wt,c=En("lazy");return T(),X(f,{active:y(ie),"onUpdate:active":l[0]||(l[0]=u=>We(ie)?ie.value=u:null),link:!0,"pt-1":""},{default:K(()=>[(T(!0),U(oe,null,ge(y(W),u=>(T(),X(s,{title:u.name,href:`/${u.id}/category`,onInited:a,key:u.id},{default:K(()=>[y(t)?(T(),U("div",ls,Z(y(t)),1)):(T(),X(f,{key:1,active:u.categoryActive.value,"onUpdate:active":h=>u.categoryActive.value=h},{default:K(()=>[(T(!0),U(oe,null,ge(u.categories.value,h=>(T(),X(s,{title:h.name,key:h.id},{default:K(()=>[v("div",ss,[(T(!0),U(oe,null,ge(h.list,d=>(T(),X(r,{to:`/${u.id}/category/${d.cid}`,"cursor-pointer":""},{default:K(()=>[Q(v("img",rs,null,512),[[c,d.pic]]),v("div",cs,Z(d.name),1)]),_:2},1032,["to"]))),256))])]),_:2},1032,["title"]))),128))]),_:2},1032,["active","onUpdate:active"]))]),_:2},1032,["title","href"]))),128))]),_:1},8,["active"])}}}),fs={"text-center":"","py-1":""},ds={class:"w-60% max-w-md pos-relative inline-block"},hs={class:"h-[calc(100%-3rem)]"},_s={key:1},ps={key:1},vs=le({__name:"search",setup(e){const n=D(""),t=J(()=>W[ie.value]),a=D(),i=()=>{if(!n.value)return Promise.resolve();const u=t.value.search;u.list.value=[],u.page=1,u.hasMore=!0,a.value="搜索中...";const h=t.value.id;return De(h,"searchRooms",{page:u.page,kw:n.value}).then(d=>{u.list.value=d.list,u.hasMore=d.hasMore,u.page+=1,a.value="finished",Se[h]||(Se[h]=d.cookie)},d=>a.value=d)},l=u=>{const h=t.value.search,d=t.value.id;u("loading"),De(d,"searchRooms",{page:h.page,kw:n.value}).then(w=>{if(h.list.value=h.list.value.concat(w.list),h.hasMore=w.hasMore,Se[d]||(Se[d]=w.cookie),!h.hasMore)return u("finshed");h.page+=1,u("normal")},w=>{u("loaderror")})},r=u=>{s.push(`/${ht[u]}/search`),!f()&&W[u].search.page==1&&i()},s=Cn(),f=()=>{if(n.value)return/^[\d]*$/.test(n.value)?(s.push(`/play/${t.value.id}/${n.value}`),!0):!1},c=()=>{f()||(W.forEach(u=>u.search.page=1),i())};return(u,h)=>{const d=vi,w=zn,I=Yt,L=Wt;return T(),U(oe,null,[v("div",fs,[v("div",ds,[Q(v("input",{"md:text-4":"",type:"text","onUpdate:modelValue":h[0]||(h[0]=E=>We(n)?n.value=E:null),"box-border":"","w-full":"","py-2.5":"","pl-3":"","pr-9":"","text-white":"","bg-transparent":"","b-1":"","b-green":"","rounded-6":"","outline-0":"",onKeydown:nl(c,["enter"]),placeholder:"请输入房间号或关键字"},null,544),[[hi,y(n),void 0,{trim:!0}]]),v("div",{class:"i-ri-search-line top-50%",absolute:"","right-3":"",onClick:c,style:{transform:"translateY(-50%)"}})])]),v("div",hs,[H(L,{active:y(ie),"onUpdate:active":h[1]||(h[1]=E=>We(ie)?ie.value=E:null),onTabClick:r},{default:K(()=>[(T(!0),U(oe,null,ge(y(W),E=>(T(),X(I,{title:E.name,key:E.id},{default:K(()=>[y(a)=="finished"?(T(),U(oe,{key:0},[E.search.list.value.length?(T(),X(w,{key:0,onLoad:l},{default:K(()=>[H(d,{list:E.search.list},null,8,["list"])]),_:2},1024)):(T(),U("div",_s," 什么也没有找到 "))],64)):(T(),U("div",ps,Z(y(a)),1))]),_:2},1032,["title"]))),128))]),_:1},8,["active"])])],64)}}}),gs=["data-id","data-site","href"],ms={"pos-relative":"","text-fuchsia-5":"","rounded-t-2":"","w-full":"","aspect-video":""},ws={block:"","mx-auto":"","text-center":"","h-full":"","rounded-2":"","select-none":""},xs={"pos-absolute":"","bottom-0":"","right-0":"","px-2":"","py-1":"","rounded-tl-2":"","bg-dark-6":""},ys={"line-height-none":"","pos-absolute":"","top-0":"","right-0":"","px-1":"","py-1":"","rounded-tr-1":"","rounded-bl-2":"","bg-dark-6":""},bs={key:0,"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":""},ks=["onClick"],Ss={"px-2":"","text-truncate":"","leading-normal":""},As={"px-2":"","text-truncate":"","leading-normal":"","pb-2":""},Es=le({__name:"rooms2",props:{list:{}},setup(e){let n;const t=Cn(),a=D(),i=s=>{clearTimeout(n),n=setTimeout(()=>{const f=r("id",s.target,a.value);if(!f)return;const c=r("site",s.target,a.value);t.push(`/${c}/play/${f}`)},300)},l=s=>{var h;clearTimeout(n);const f=r("id",s.target,a.value);if(!f)return;const u=`/${r("site",s.target,a.value)}/play/${f}`;(h=window.open(u,"_blank"))==null||h.location},r=(s,f,c)=>{if(f==c)return null;const u=f.dataset[s];return u||r(s,f.parentElement,c)};return(s,f)=>{const c=En("lazy");return s.list.value.length>0?(T(),U("div",{key:0,ref_key:"root",ref:a,grid:"","gap-4":"","p-2":"","justify-evenly":"","cursor-pointer":"","select-none":"","grid-cols-2":"","md:grid-cols-3":"","xl:grid-cols-4":"",class:"2xl:grid-cols-5",onClick:q(i,["prevent"]),onDblclick:q(l,["prevent"])},[(T(!0),U(oe,null,ge(s.list.value,u=>(T(),U("a",{"data-id":u.roomId,"data-site":u.siteId,href:`/${u.siteId}/play/${u.roomId}`,key:`${u.siteId}-${u.roomId}`,shadow:"","rounded-2":"","b-2px":"","b-solid":"","b-transparent":"","hover:b-amber":"","overflow-hidden":""},[v("div",ms,[Q(v("img",ws,null,512),[[c,u.cover]]),v("div",xs,Z(u.category),1),v("div",ys,[f[0]||(f[0]=v("div",{class:"i-mdi-fire"},null,-1)),v("span",null,Z(u.online),1)]),u.status?Le("",!0):(T(),U("div",bs," 未开播 ")),v("div",{"pos-absolute":"","z-1":"","left-2":"","top-2":"","text-green-5":"","w-6":"","h-6":"","hover:text-amber":"",class:"i-mdi-heart-off-outline",onClick:h=>y(ii)(u.siteId,u.roomId)},null,8,ks)]),v("div",Ss,Z(u.title),1),v("div",As,Z(u.nickname),1)],8,gs))),128))],544)):Le("",!0)}}}),Is={flex:"","items-center":""},Ts={"grow-1":"","justify-center":"","gap-2":"","p-2":"",flex:""},Cs={"pos-relative":"",flex:"","gap-2":""},zs={"pos-absolute":"","top-0":"","right-0":"",style:{transform:"translateX(150%)"},"rounded-6":"","bg-white":"",shadow:"","text-amber":""},Rs={class:"bg-gray-7 gap-4 p-12 rounded-2 flex flex-col shadow relative mt-30"},Ms={class:"flex justify-center items-center"},Os={class:"flex gap-4"},Ls={class:"py-2 min-w-16"},Ds={class:"flex gap-4"},Us={class:"py-2 min-w-16"},Bs={class:"h-[calc(100%-3rem)]"},$s=le({__name:"follow",setup(e){const n=yn(W,E=>({name:E.name,list:J(()=>Object.values(E.follows).sort(k=>k.status?-1:0))}));n.unshift({name:"全部",list:J(()=>W.map(E=>Object.values(E.follows)).flat().sort(E=>E.status?-1:0))});const t=D(0),a=()=>{var k;if(l.value)return;const E=t.value;l.value=!0,E==0?Promise.all(yn(W,ni)).finally(i):(k=ni(W[E-1]))==null||k.finally(i)},i=()=>setTimeout(()=>l.value=!1,300),l=D(!1),r=D(""),s=D(!1),f=D([]),c=D(!1),u=()=>setTimeout(()=>c.value=!1,300),h=()=>{c.value||(c.value=!0,ml(n[0].list.value).then(E=>{r.value=E,f.value=n[0].list.value}).finally(u))},d=()=>{if(!c.value){if(!/^\d{4}$/.test(r.value))return r.value="";c.value=!0,wl(r.value).then(E=>{f.value=E},E=>r.value=E).finally(u)}},w=()=>{if(!c.value){if(c.value=!0,r.value.startsWith("[")){try{const E=JSON.parse(r.value);Vo(E,k=>{/^\d+$/.test(k.roomId)&&Mt({siteId:k.siteId,roomId:k.roomId,cover:k.face,nickname:k.userName})})}catch{r.value="合并失败"}return u()}f.value.forEach(E=>Mt(E)),u()}},I=()=>{c.value||(c.value=!0,yl(),f.value.forEach(E=>Mt(E)),u())};a();const L=E=>E("finshed");return(E,k)=>{const M=Es,S=zn,b=Yt,x=Wt;return T(),U(oe,null,[v("div",Is,[v("div",Ts,[v("div",Cs,[k[6]||(k[6]=Rt("关注用户 ")),v("button",{class:"bg-green-5 rounded border-none cursor-pointer",onClick:k[0]||(k[0]=p=>s.value=!0)},"同步"),v("button",{class:"bg-green-5 rounded border-none cursor-pointer",onClick:a},"刷新"),Q(v("div",zs,k[5]||(k[5]=[v("div",{class:"i-ri-refresh-line animate-spin"},null,-1)]),512),[[ke,y(l)]])]),Q(v("div",{class:"absolute z-10 top-0 left-0 right-0 bottom-0 flex justify-center items-start",onClick:k[3]||(k[3]=q(p=>s.value=!1,["self"]))},[v("div",Rs,[v("div",Ms,[k[8]||(k[8]=v("div",{class:"text-8"},"同步",-1)),Q(v("div",null,k[7]||(k[7]=[v("div",{class:"i-ri-refresh-line animate-spin"},null,-1)]),512),[[ke,y(c)]])]),Q(v("input",{class:"outline-none p-2 border-none rounded-2 flex-1","onUpdate:modelValue":k[1]||(k[1]=p=>We(r)?r.value=p:null),type:"text",placeholder:"key"},null,512),[[hi,y(r)]]),v("div",Os,[v("div",Ls,"本地 "+Z(y(n)[0].list.value.length),1),v("div",{onClick:w,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"}," 合并 "),v("div",{onClick:I,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"覆盖")]),v("div",Ds,[v("div",Us,"云端 "+Z(y(f).length),1),v("div",{onClick:d,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"拉取"),v("div",{onClick:h,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"推送")]),k[9]||(k[9]=v("div",null,[v("div",null,"1. key 有效期 10 分钟"),v("div",null,"2. 拉取需要输入 key"),v("div",null,"3. 推送自动生成 key ")],-1)),v("div",{onClick:k[2]||(k[2]=q(p=>s.value=!1,["stop"])),class:"i-ri-close-circle-line absolute right-2 top-2"})])],512),[[ke,y(s)]])])]),v("div",Bs,[H(x,{active:y(t),"onUpdate:active":k[4]||(k[4]=p=>We(t)?t.value=p:null)},{default:K(()=>[(T(!0),U(oe,null,ge(y(n),p=>(T(),X(b,{title:p.name},{default:K(()=>[H(S,{onLoad:L,"finshed-text":""},{default:K(()=>[H(M,{list:p.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["title"]))),256))]),_:1},8,["active"])])],64)}}}),Fs=le({__name:"index",setup(e){const n=J(()=>W[ie.value].id),t=a=>{const i=W[ie.value].recommend;De(n.value,"getRecommendRooms",{page:i.page}).then(l=>{if(i.list.value=i.list.value.concat(l.list),i.hasMore=l.hasMore,Se[n.value]||(Se[n.value]=l.cookie),!i.hasMore)return a("finshed");i.page++,a("normal")},()=>a("loaderror"))};return(a,i)=>{const l=vi,r=zn,s=Yt,f=Wt;return T(),X(f,{active:y(ie),"onUpdate:active":i[0]||(i[0]=c=>We(ie)?ie.value=c:null),link:!0,"pt-1":""},{default:K(()=>[(T(!0),U(oe,null,ge(y(W),c=>(T(),X(s,{href:`/${c.id}`,key:c.id,title:c.name,"pos-relative":""},{default:K(()=>[H(r,{onLoad:t,"h-full":""},{default:K(()=>[H(l,{list:c.recommend.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["href","title"]))),128))]),_:1},8,["active"])}}}),Ns=le({__name:"switch",props:{value:{type:Boolean,required:!0},valueModifiers:{}},emits:["update:value"],setup(e){const n=Kt(e,"value");return(t,a)=>(T(),U("div",{"pos-relative":"",style:{transition:"background-color .3s"},onClick:a[0]||(a[0]=()=>n.value=!n.value),"w-12":"","inline-block":"","cursor-pointer":"","rounded-6":"","h-6":"",class:Y([n.value?"bg-amber":"bg-gray-4"])},[v("div",{"w-6":"","h-full":"","rounded-6":"","bg-white":"",style:dt([{transition:"transform .3s"},n.value?"transform:translateX(1.5rem)":""])},null,4)],2))}}),Zs={"rounded-4":"",flex:"","bg-gray-7":"","w-min":"","p-2":"","py-1":"","gap-2":""},js=le({__name:"stepper",props:Bt({max:{},min:{},step:{}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(e){const n=e,t=Kt(e,"value"),a=()=>t.value=Math.min(t.value+n.step,n.max),i=()=>t.value=Math.max(t.value-n.step,n.min);return(l,r)=>(T(),U("div",Zs,[v("div",{class:"i-ri-subtract-fill",onClick:i}),v("div",null,Z(t.value),1),v("div",{class:"i-ri-add-fill",onClick:a})]))}});function Ps(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}const mn=Ps(),Hs=e=>mn?e.touches==null?e:e.touches[0]||e.changedTouches[0]:e,Vs=le({__name:"slider",props:Bt({max:{default:100},min:{default:0},width:{default:30},height:{default:100}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(e){const n=e,t=Kt(e,"value"),a=D(),i=n.width<n.height;let l;const r=h=>{h.stopPropagation(),c(h),document.addEventListener("mousemove",c,!0),document.addEventListener("mouseup",u,!0)},s=J(()=>(t.value-n.min)/(n.max-n.min)*100),f=J(()=>{const h=100-s.value,d=`top:${h}%`,w=`left:${h}%`;return i?{loaded:d,indicator:d}:{loaded:`${w};transform:translateX(-100%)`,indicator:w}}),c=h=>{h.stopPropagation(),h=Hs(h);const w=100-(Math.min(i?l.height:l.width,Math.max(0,i?h.clientY-l.y:h.clientX-l.x))/(i?l.height:l.width)*100|0);t.value=((n.max-n.min)*w|0)/100+n.min|0},u=h=>{h.stopPropagation(),document.removeEventListener("mousemove",c,!0),document.removeEventListener("mouseup",u,!0)};return wt(()=>{l=a.value.getBoundingClientRect(),a.value.addEventListener("mousedown",r,!0)}),In(()=>{a.value.removeEventListener("mousedown",r,!0)}),(h,d)=>(T(),U("div",{"cursor-pointer":"",style:dt({width:`${n.width}px`,height:`${n.height}px`}),class:Y(i?" py-4 ":"px-4"),flex:"","justify-center":""},[v("div",{"w-full":"","h-full":"","pos-relative":"",flex:"","justify-center":"","items-center":"",ref_key:"root",ref:a,onClick:c},[v("div",{"bg-gray":"","pos-relative":"","overflow-hidden":"",class:Y(i?"h-full w-2px":"w-full h-2px")},[v("div",{"w-full":"","bg-amber":"","h-full":"","pos-absolute":"",style:dt(y(f).loaded)},null,4)],2),v("div",{"pos-absolute":"","w-12px":"","h-12px":"","bg-amber":"","rounded-2":"",style:dt(y(f).indicator),class:Y(i?"-mt-6px":"-ml-6px")},null,6)],512)],6))}}),Gs={key:0,"z-1":"",fixed:"","top-0":"","bottom-0":"","left-0":"","right-0":"","bg-transparent":"","data-index":"-1"},Ks={"p-1":"","data-index":"-1","hover:text-amber":""},Ws={"text-center":"","z-1":"","pos-absolute":"","top-0":"",class:"left-50%","w-max":"",style:{transform:"translate3d(-50%,-100%,0)"}},Ys=["data-index"],Qs=le({__name:"select",props:Bt(["list"],{active:{required:!0},activeModifiers:{}}),emits:["update:active"],setup(e){const n=Kt(e,"active"),t=D(!1),a=i=>{const l=i.target.dataset.index;l&&(l!="-1"&&(n.value=parseInt(l)),t.value=!t.value)};return(i,l)=>(T(),U("div",{"inline-block":"","pos-relative":"",onClick:a,"cursor-pointer":"","text-center":""},[y(t)?(T(),U("div",Gs)):Le("",!0),v("div",Ks,Z(e.list[n.value]),1),Q(v("div",Ws,[(T(!0),U(oe,null,ge(e.list,(r,s)=>(T(),U("div",{"data-index":s,class:Y({"text-amber":s==n.value}),"p-1":"","hover:text-amber":""},Z(r),11,Ys))),256))],512),[[ke,y(t)]])]))}}),Pi="data:image/png;base64,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",Hi="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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",rn=window.Flv,cn=window.Hls;/*! pako 2.1.0 https://github.com/nodeca/pako @license (MIT AND Zlib) */const Js=4,Vi=0,Gi=1,qs=2;function yt(e){let n=e.length;for(;--n>=0;)e[n]=0}const Xs=0,Yo=1,er=2,tr=3,nr=258,gi=29,Qt=256,$t=Qt+1+gi,_t=30,mi=19,Qo=2*$t+1,Xe=15,Nn=16,ir=7,wi=256,Jo=16,qo=17,Xo=18,oi=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),wn=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),or=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),ea=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),ar=512,Be=new Array(($t+2)*2);yt(Be);const Ot=new Array(_t*2);yt(Ot);const Ft=new Array(ar);yt(Ft);const Nt=new Array(nr-tr+1);yt(Nt);const xi=new Array(gi);yt(xi);const bn=new Array(_t);yt(bn);function Zn(e,n,t,a,i){this.static_tree=e,this.extra_bits=n,this.extra_base=t,this.elems=a,this.max_length=i,this.has_stree=e&&e.length}let ta,na,ia;function jn(e,n){this.dyn_tree=e,this.max_code=0,this.stat_desc=n}const oa=e=>e<256?Ft[e]:Ft[256+(e>>>7)],Zt=(e,n)=>{e.pending_buf[e.pending++]=n&255,e.pending_buf[e.pending++]=n>>>8&255},ve=(e,n,t)=>{e.bi_valid>Nn-t?(e.bi_buf|=n<<e.bi_valid&65535,Zt(e,e.bi_buf),e.bi_buf=n>>Nn-e.bi_valid,e.bi_valid+=t-Nn):(e.bi_buf|=n<<e.bi_valid&65535,e.bi_valid+=t)},Re=(e,n,t)=>{ve(e,t[n*2],t[n*2+1])},aa=(e,n)=>{let t=0;do t|=e&1,e>>>=1,t<<=1;while(--n>0);return t>>>1},lr=e=>{e.bi_valid===16?(Zt(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=e.bi_buf&255,e.bi_buf>>=8,e.bi_valid-=8)},sr=(e,n)=>{const t=n.dyn_tree,a=n.max_code,i=n.stat_desc.static_tree,l=n.stat_desc.has_stree,r=n.stat_desc.extra_bits,s=n.stat_desc.extra_base,f=n.stat_desc.max_length;let c,u,h,d,w,I,L=0;for(d=0;d<=Xe;d++)e.bl_count[d]=0;for(t[e.heap[e.heap_max]*2+1]=0,c=e.heap_max+1;c<Qo;c++)u=e.heap[c],d=t[t[u*2+1]*2+1]+1,d>f&&(d=f,L++),t[u*2+1]=d,!(u>a)&&(e.bl_count[d]++,w=0,u>=s&&(w=r[u-s]),I=t[u*2],e.opt_len+=I*(d+w),l&&(e.static_len+=I*(i[u*2+1]+w)));if(L!==0){do{for(d=f-1;e.bl_count[d]===0;)d--;e.bl_count[d]--,e.bl_count[d+1]+=2,e.bl_count[f]--,L-=2}while(L>0);for(d=f;d!==0;d--)for(u=e.bl_count[d];u!==0;)h=e.heap[--c],!(h>a)&&(t[h*2+1]!==d&&(e.opt_len+=(d-t[h*2+1])*t[h*2],t[h*2+1]=d),u--)}},la=(e,n,t)=>{const a=new Array(Xe+1);let i=0,l,r;for(l=1;l<=Xe;l++)i=i+t[l-1]<<1,a[l]=i;for(r=0;r<=n;r++){let s=e[r*2+1];s!==0&&(e[r*2]=aa(a[s]++,s))}},rr=()=>{let e,n,t,a,i;const l=new Array(Xe+1);for(t=0,a=0;a<gi-1;a++)for(xi[a]=t,e=0;e<1<<oi[a];e++)Nt[t++]=a;for(Nt[t-1]=a,i=0,a=0;a<16;a++)for(bn[a]=i,e=0;e<1<<wn[a];e++)Ft[i++]=a;for(i>>=7;a<_t;a++)for(bn[a]=i<<7,e=0;e<1<<wn[a]-7;e++)Ft[256+i++]=a;for(n=0;n<=Xe;n++)l[n]=0;for(e=0;e<=143;)Be[e*2+1]=8,e++,l[8]++;for(;e<=255;)Be[e*2+1]=9,e++,l[9]++;for(;e<=279;)Be[e*2+1]=7,e++,l[7]++;for(;e<=287;)Be[e*2+1]=8,e++,l[8]++;for(la(Be,$t+1,l),e=0;e<_t;e++)Ot[e*2+1]=5,Ot[e*2]=aa(e,5);ta=new Zn(Be,oi,Qt+1,$t,Xe),na=new Zn(Ot,wn,0,_t,Xe),ia=new Zn(new Array(0),or,0,mi,ir)},sa=e=>{let n;for(n=0;n<$t;n++)e.dyn_ltree[n*2]=0;for(n=0;n<_t;n++)e.dyn_dtree[n*2]=0;for(n=0;n<mi;n++)e.bl_tree[n*2]=0;e.dyn_ltree[wi*2]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},ra=e=>{e.bi_valid>8?Zt(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},Ki=(e,n,t,a)=>{const i=n*2,l=t*2;return e[i]<e[l]||e[i]===e[l]&&a[n]<=a[t]},Pn=(e,n,t)=>{const a=e.heap[t];let i=t<<1;for(;i<=e.heap_len&&(i<e.heap_len&&Ki(n,e.heap[i+1],e.heap[i],e.depth)&&i++,!Ki(n,a,e.heap[i],e.depth));)e.heap[t]=e.heap[i],t=i,i<<=1;e.heap[t]=a},Wi=(e,n,t)=>{let a,i,l=0,r,s;if(e.sym_next!==0)do a=e.pending_buf[e.sym_buf+l++]&255,a+=(e.pending_buf[e.sym_buf+l++]&255)<<8,i=e.pending_buf[e.sym_buf+l++],a===0?Re(e,i,n):(r=Nt[i],Re(e,r+Qt+1,n),s=oi[r],s!==0&&(i-=xi[r],ve(e,i,s)),a--,r=oa(a),Re(e,r,t),s=wn[r],s!==0&&(a-=bn[r],ve(e,a,s)));while(l<e.sym_next);Re(e,wi,n)},ai=(e,n)=>{const t=n.dyn_tree,a=n.stat_desc.static_tree,i=n.stat_desc.has_stree,l=n.stat_desc.elems;let r,s,f=-1,c;for(e.heap_len=0,e.heap_max=Qo,r=0;r<l;r++)t[r*2]!==0?(e.heap[++e.heap_len]=f=r,e.depth[r]=0):t[r*2+1]=0;for(;e.heap_len<2;)c=e.heap[++e.heap_len]=f<2?++f:0,t[c*2]=1,e.depth[c]=0,e.opt_len--,i&&(e.static_len-=a[c*2+1]);for(n.max_code=f,r=e.heap_len>>1;r>=1;r--)Pn(e,t,r);c=l;do r=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Pn(e,t,1),s=e.heap[1],e.heap[--e.heap_max]=r,e.heap[--e.heap_max]=s,t[c*2]=t[r*2]+t[s*2],e.depth[c]=(e.depth[r]>=e.depth[s]?e.depth[r]:e.depth[s])+1,t[r*2+1]=t[s*2+1]=c,e.heap[1]=c++,Pn(e,t,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],sr(e,n),la(t,f,e.bl_count)},Yi=(e,n,t)=>{let a,i=-1,l,r=n[0*2+1],s=0,f=7,c=4;for(r===0&&(f=138,c=3),n[(t+1)*2+1]=65535,a=0;a<=t;a++)l=r,r=n[(a+1)*2+1],!(++s<f&&l===r)&&(s<c?e.bl_tree[l*2]+=s:l!==0?(l!==i&&e.bl_tree[l*2]++,e.bl_tree[Jo*2]++):s<=10?e.bl_tree[qo*2]++:e.bl_tree[Xo*2]++,s=0,i=l,r===0?(f=138,c=3):l===r?(f=6,c=3):(f=7,c=4))},Qi=(e,n,t)=>{let a,i=-1,l,r=n[0*2+1],s=0,f=7,c=4;for(r===0&&(f=138,c=3),a=0;a<=t;a++)if(l=r,r=n[(a+1)*2+1],!(++s<f&&l===r)){if(s<c)do Re(e,l,e.bl_tree);while(--s!==0);else l!==0?(l!==i&&(Re(e,l,e.bl_tree),s--),Re(e,Jo,e.bl_tree),ve(e,s-3,2)):s<=10?(Re(e,qo,e.bl_tree),ve(e,s-3,3)):(Re(e,Xo,e.bl_tree),ve(e,s-11,7));s=0,i=l,r===0?(f=138,c=3):l===r?(f=6,c=3):(f=7,c=4)}},cr=e=>{let n;for(Yi(e,e.dyn_ltree,e.l_desc.max_code),Yi(e,e.dyn_dtree,e.d_desc.max_code),ai(e,e.bl_desc),n=mi-1;n>=3&&e.bl_tree[ea[n]*2+1]===0;n--);return e.opt_len+=3*(n+1)+5+5+4,n},ur=(e,n,t,a)=>{let i;for(ve(e,n-257,5),ve(e,t-1,5),ve(e,a-4,4),i=0;i<a;i++)ve(e,e.bl_tree[ea[i]*2+1],3);Qi(e,e.dyn_ltree,n-1),Qi(e,e.dyn_dtree,t-1)},fr=e=>{let n=4093624447,t;for(t=0;t<=31;t++,n>>>=1)if(n&1&&e.dyn_ltree[t*2]!==0)return Vi;if(e.dyn_ltree[9*2]!==0||e.dyn_ltree[10*2]!==0||e.dyn_ltree[13*2]!==0)return Gi;for(t=32;t<Qt;t++)if(e.dyn_ltree[t*2]!==0)return Gi;return Vi};let Ji=!1;const dr=e=>{Ji||(rr(),Ji=!0),e.l_desc=new jn(e.dyn_ltree,ta),e.d_desc=new jn(e.dyn_dtree,na),e.bl_desc=new jn(e.bl_tree,ia),e.bi_buf=0,e.bi_valid=0,sa(e)},ca=(e,n,t,a)=>{ve(e,(Xs<<1)+(a?1:0),3),ra(e),Zt(e,t),Zt(e,~t),t&&e.pending_buf.set(e.window.subarray(n,n+t),e.pending),e.pending+=t},hr=e=>{ve(e,Yo<<1,3),Re(e,wi,Be),lr(e)},_r=(e,n,t,a)=>{let i,l,r=0;e.level>0?(e.strm.data_type===qs&&(e.strm.data_type=fr(e)),ai(e,e.l_desc),ai(e,e.d_desc),r=cr(e),i=e.opt_len+3+7>>>3,l=e.static_len+3+7>>>3,l<=i&&(i=l)):i=l=t+5,t+4<=i&&n!==-1?ca(e,n,t,a):e.strategy===Js||l===i?(ve(e,(Yo<<1)+(a?1:0),3),Wi(e,Be,Ot)):(ve(e,(er<<1)+(a?1:0),3),ur(e,e.l_desc.max_code+1,e.d_desc.max_code+1,r+1),Wi(e,e.dyn_ltree,e.dyn_dtree)),sa(e),a&&ra(e)},pr=(e,n,t)=>(e.pending_buf[e.sym_buf+e.sym_next++]=n,e.pending_buf[e.sym_buf+e.sym_next++]=n>>8,e.pending_buf[e.sym_buf+e.sym_next++]=t,n===0?e.dyn_ltree[t*2]++:(e.matches++,n--,e.dyn_ltree[(Nt[t]+Qt+1)*2]++,e.dyn_dtree[oa(n)*2]++),e.sym_next===e.sym_end);var vr=dr,gr=ca,mr=_r,wr=pr,xr=hr,yr={_tr_init:vr,_tr_stored_block:gr,_tr_flush_block:mr,_tr_tally:wr,_tr_align:xr};const br=(e,n,t,a)=>{let i=e&65535|0,l=e>>>16&65535|0,r=0;for(;t!==0;){r=t>2e3?2e3:t,t-=r;do i=i+n[a++]|0,l=l+i|0;while(--r);i%=65521,l%=65521}return i|l<<16|0};var jt=br;const kr=()=>{let e,n=[];for(var t=0;t<256;t++){e=t;for(var a=0;a<8;a++)e=e&1?3988292384^e>>>1:e>>>1;n[t]=e}return n},Sr=new Uint32Array(kr()),Ar=(e,n,t,a)=>{const i=Sr,l=a+t;e^=-1;for(let r=a;r<l;r++)e=e>>>8^i[(e^n[r])&255];return e^-1};var ne=Ar,vt={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"},Jt={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};const{_tr_init:Er,_tr_stored_block:li,_tr_flush_block:Ir,_tr_tally:Ve,_tr_align:Tr}=yr,{Z_NO_FLUSH:Ge,Z_PARTIAL_FLUSH:Cr,Z_FULL_FLUSH:zr,Z_FINISH:Ie,Z_BLOCK:qi,Z_OK:ae,Z_STREAM_END:Xi,Z_STREAM_ERROR:Me,Z_DATA_ERROR:Rr,Z_BUF_ERROR:Hn,Z_DEFAULT_COMPRESSION:Mr,Z_FILTERED:Or,Z_HUFFMAN_ONLY:un,Z_RLE:Lr,Z_FIXED:Dr,Z_DEFAULT_STRATEGY:Ur,Z_UNKNOWN:Br,Z_DEFLATED:Rn}=Jt,$r=9,Fr=15,Nr=8,Zr=29,jr=256,si=jr+1+Zr,Pr=30,Hr=19,Vr=2*si+1,Gr=15,j=3,Pe=258,Oe=Pe+j+1,Kr=32,gt=42,yi=57,ri=69,ci=73,ui=91,fi=103,et=113,Ct=666,_e=1,bt=2,nt=3,kt=4,Wr=3,tt=(e,n)=>(e.msg=vt[n],n),eo=e=>e*2-(e>4?9:0),Ze=e=>{let n=e.length;for(;--n>=0;)e[n]=0},Yr=e=>{let n,t,a,i=e.w_size;n=e.hash_size,a=n;do t=e.head[--a],e.head[a]=t>=i?t-i:0;while(--n);n=i,a=n;do t=e.prev[--a],e.prev[a]=t>=i?t-i:0;while(--n)};let Qr=(e,n,t)=>(n<<e.hash_shift^t)&e.hash_mask,Ke=Qr;const ye=e=>{const n=e.state;let t=n.pending;t>e.avail_out&&(t=e.avail_out),t!==0&&(e.output.set(n.pending_buf.subarray(n.pending_out,n.pending_out+t),e.next_out),e.next_out+=t,n.pending_out+=t,e.total_out+=t,e.avail_out-=t,n.pending-=t,n.pending===0&&(n.pending_out=0))},Ae=(e,n)=>{Ir(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,n),e.block_start=e.strstart,ye(e.strm)},P=(e,n)=>{e.pending_buf[e.pending++]=n},It=(e,n)=>{e.pending_buf[e.pending++]=n>>>8&255,e.pending_buf[e.pending++]=n&255},di=(e,n,t,a)=>{let i=e.avail_in;return i>a&&(i=a),i===0?0:(e.avail_in-=i,n.set(e.input.subarray(e.next_in,e.next_in+i),t),e.state.wrap===1?e.adler=jt(e.adler,n,i,t):e.state.wrap===2&&(e.adler=ne(e.adler,n,i,t)),e.next_in+=i,e.total_in+=i,i)},ua=(e,n)=>{let t=e.max_chain_length,a=e.strstart,i,l,r=e.prev_length,s=e.nice_match;const f=e.strstart>e.w_size-Oe?e.strstart-(e.w_size-Oe):0,c=e.window,u=e.w_mask,h=e.prev,d=e.strstart+Pe;let w=c[a+r-1],I=c[a+r];e.prev_length>=e.good_match&&(t>>=2),s>e.lookahead&&(s=e.lookahead);do if(i=n,!(c[i+r]!==I||c[i+r-1]!==w||c[i]!==c[a]||c[++i]!==c[a+1])){a+=2,i++;do;while(c[++a]===c[++i]&&c[++a]===c[++i]&&c[++a]===c[++i]&&c[++a]===c[++i]&&c[++a]===c[++i]&&c[++a]===c[++i]&&c[++a]===c[++i]&&c[++a]===c[++i]&&a<d);if(l=Pe-(d-a),a=d-Pe,l>r){if(e.match_start=n,r=l,l>=s)break;w=c[a+r-1],I=c[a+r]}}while((n=h[n&u])>f&&--t!==0);return r<=e.lookahead?r:e.lookahead},mt=e=>{const n=e.w_size;let t,a,i;do{if(a=e.window_size-e.lookahead-e.strstart,e.strstart>=n+(n-Oe)&&(e.window.set(e.window.subarray(n,n+n-a),0),e.match_start-=n,e.strstart-=n,e.block_start-=n,e.insert>e.strstart&&(e.insert=e.strstart),Yr(e),a+=n),e.strm.avail_in===0)break;if(t=di(e.strm,e.window,e.strstart+e.lookahead,a),e.lookahead+=t,e.lookahead+e.insert>=j)for(i=e.strstart-e.insert,e.ins_h=e.window[i],e.ins_h=Ke(e,e.ins_h,e.window[i+1]);e.insert&&(e.ins_h=Ke(e,e.ins_h,e.window[i+j-1]),e.prev[i&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=i,i++,e.insert--,!(e.lookahead+e.insert<j)););}while(e.lookahead<Oe&&e.strm.avail_in!==0)},fa=(e,n)=>{let t=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,a,i,l,r=0,s=e.strm.avail_in;do{if(a=65535,l=e.bi_valid+42>>3,e.strm.avail_out<l||(l=e.strm.avail_out-l,i=e.strstart-e.block_start,a>i+e.strm.avail_in&&(a=i+e.strm.avail_in),a>l&&(a=l),a<t&&(a===0&&n!==Ie||n===Ge||a!==i+e.strm.avail_in)))break;r=n===Ie&&a===i+e.strm.avail_in?1:0,li(e,0,0,r),e.pending_buf[e.pending-4]=a,e.pending_buf[e.pending-3]=a>>8,e.pending_buf[e.pending-2]=~a,e.pending_buf[e.pending-1]=~a>>8,ye(e.strm),i&&(i>a&&(i=a),e.strm.output.set(e.window.subarray(e.block_start,e.block_start+i),e.strm.next_out),e.strm.next_out+=i,e.strm.avail_out-=i,e.strm.total_out+=i,e.block_start+=i,a-=i),a&&(di(e.strm,e.strm.output,e.strm.next_out,a),e.strm.next_out+=a,e.strm.avail_out-=a,e.strm.total_out+=a)}while(r===0);return s-=e.strm.avail_in,s&&(s>=e.w_size?(e.matches=2,e.window.set(e.strm.input.subarray(e.strm.next_in-e.w_size,e.strm.next_in),0),e.strstart=e.w_size,e.insert=e.strstart):(e.window_size-e.strstart<=s&&(e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,e.insert>e.strstart&&(e.insert=e.strstart)),e.window.set(e.strm.input.subarray(e.strm.next_in-s,e.strm.next_in),e.strstart),e.strstart+=s,e.insert+=s>e.w_size-e.insert?e.w_size-e.insert:s),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),r?kt:n!==Ge&&n!==Ie&&e.strm.avail_in===0&&e.strstart===e.block_start?bt:(l=e.window_size-e.strstart,e.strm.avail_in>l&&e.block_start>=e.w_size&&(e.block_start-=e.w_size,e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,l+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),l>e.strm.avail_in&&(l=e.strm.avail_in),l&&(di(e.strm,e.window,e.strstart,l),e.strstart+=l,e.insert+=l>e.w_size-e.insert?e.w_size-e.insert:l),e.high_water<e.strstart&&(e.high_water=e.strstart),l=e.bi_valid+42>>3,l=e.pending_buf_size-l>65535?65535:e.pending_buf_size-l,t=l>e.w_size?e.w_size:l,i=e.strstart-e.block_start,(i>=t||(i||n===Ie)&&n!==Ge&&e.strm.avail_in===0&&i<=l)&&(a=i>l?l:i,r=n===Ie&&e.strm.avail_in===0&&a===i?1:0,li(e,e.block_start,a,r),e.block_start+=a,ye(e.strm)),r?nt:_e)},Vn=(e,n)=>{let t,a;for(;;){if(e.lookahead<Oe){if(mt(e),e.lookahead<Oe&&n===Ge)return _e;if(e.lookahead===0)break}if(t=0,e.lookahead>=j&&(e.ins_h=Ke(e,e.ins_h,e.window[e.strstart+j-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),t!==0&&e.strstart-t<=e.w_size-Oe&&(e.match_length=ua(e,t)),e.match_length>=j)if(a=Ve(e,e.strstart-e.match_start,e.match_length-j),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=j){e.match_length--;do e.strstart++,e.ins_h=Ke(e,e.ins_h,e.window[e.strstart+j-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(--e.match_length!==0);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=Ke(e,e.ins_h,e.window[e.strstart+1]);else a=Ve(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(a&&(Ae(e,!1),e.strm.avail_out===0))return _e}return e.insert=e.strstart<j-1?e.strstart:j-1,n===Ie?(Ae(e,!0),e.strm.avail_out===0?nt:kt):e.sym_next&&(Ae(e,!1),e.strm.avail_out===0)?_e:bt},ct=(e,n)=>{let t,a,i;for(;;){if(e.lookahead<Oe){if(mt(e),e.lookahead<Oe&&n===Ge)return _e;if(e.lookahead===0)break}if(t=0,e.lookahead>=j&&(e.ins_h=Ke(e,e.ins_h,e.window[e.strstart+j-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=j-1,t!==0&&e.prev_length<e.max_lazy_match&&e.strstart-t<=e.w_size-Oe&&(e.match_length=ua(e,t),e.match_length<=5&&(e.strategy===Or||e.match_length===j&&e.strstart-e.match_start>4096)&&(e.match_length=j-1)),e.prev_length>=j&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-j,a=Ve(e,e.strstart-1-e.prev_match,e.prev_length-j),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=i&&(e.ins_h=Ke(e,e.ins_h,e.window[e.strstart+j-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(--e.prev_length!==0);if(e.match_available=0,e.match_length=j-1,e.strstart++,a&&(Ae(e,!1),e.strm.avail_out===0))return _e}else if(e.match_available){if(a=Ve(e,0,e.window[e.strstart-1]),a&&Ae(e,!1),e.strstart++,e.lookahead--,e.strm.avail_out===0)return _e}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(a=Ve(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<j-1?e.strstart:j-1,n===Ie?(Ae(e,!0),e.strm.avail_out===0?nt:kt):e.sym_next&&(Ae(e,!1),e.strm.avail_out===0)?_e:bt},Jr=(e,n)=>{let t,a,i,l;const r=e.window;for(;;){if(e.lookahead<=Pe){if(mt(e),e.lookahead<=Pe&&n===Ge)return _e;if(e.lookahead===0)break}if(e.match_length=0,e.lookahead>=j&&e.strstart>0&&(i=e.strstart-1,a=r[i],a===r[++i]&&a===r[++i]&&a===r[++i])){l=e.strstart+Pe;do;while(a===r[++i]&&a===r[++i]&&a===r[++i]&&a===r[++i]&&a===r[++i]&&a===r[++i]&&a===r[++i]&&a===r[++i]&&i<l);e.match_length=Pe-(l-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=j?(t=Ve(e,1,e.match_length-j),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(t=Ve(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),t&&(Ae(e,!1),e.strm.avail_out===0))return _e}return e.insert=0,n===Ie?(Ae(e,!0),e.strm.avail_out===0?nt:kt):e.sym_next&&(Ae(e,!1),e.strm.avail_out===0)?_e:bt},qr=(e,n)=>{let t;for(;;){if(e.lookahead===0&&(mt(e),e.lookahead===0)){if(n===Ge)return _e;break}if(e.match_length=0,t=Ve(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,t&&(Ae(e,!1),e.strm.avail_out===0))return _e}return e.insert=0,n===Ie?(Ae(e,!0),e.strm.avail_out===0?nt:kt):e.sym_next&&(Ae(e,!1),e.strm.avail_out===0)?_e:bt};function ze(e,n,t,a,i){this.good_length=e,this.max_lazy=n,this.nice_length=t,this.max_chain=a,this.func=i}const zt=[new ze(0,0,0,0,fa),new ze(4,4,8,4,Vn),new ze(4,5,16,8,Vn),new ze(4,6,32,32,Vn),new ze(4,4,16,16,ct),new ze(8,16,32,32,ct),new ze(8,16,128,128,ct),new ze(8,32,128,256,ct),new ze(32,128,258,1024,ct),new ze(32,258,258,4096,ct)],Xr=e=>{e.window_size=2*e.w_size,Ze(e.head),e.max_lazy_match=zt[e.level].max_lazy,e.good_match=zt[e.level].good_length,e.nice_match=zt[e.level].nice_length,e.max_chain_length=zt[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=j-1,e.match_available=0,e.ins_h=0};function ec(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Rn,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(Vr*2),this.dyn_dtree=new Uint16Array((2*Pr+1)*2),this.bl_tree=new Uint16Array((2*Hr+1)*2),Ze(this.dyn_ltree),Ze(this.dyn_dtree),Ze(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(Gr+1),this.heap=new Uint16Array(2*si+1),Ze(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(2*si+1),Ze(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const qt=e=>{if(!e)return 1;const n=e.state;return!n||n.strm!==e||n.status!==gt&&n.status!==yi&&n.status!==ri&&n.status!==ci&&n.status!==ui&&n.status!==fi&&n.status!==et&&n.status!==Ct?1:0},da=e=>{if(qt(e))return tt(e,Me);e.total_in=e.total_out=0,e.data_type=Br;const n=e.state;return n.pending=0,n.pending_out=0,n.wrap<0&&(n.wrap=-n.wrap),n.status=n.wrap===2?yi:n.wrap?gt:et,e.adler=n.wrap===2?0:1,n.last_flush=-2,Er(n),ae},ha=e=>{const n=da(e);return n===ae&&Xr(e.state),n},tc=(e,n)=>qt(e)||e.state.wrap!==2?Me:(e.state.gzhead=n,ae),_a=(e,n,t,a,i,l)=>{if(!e)return Me;let r=1;if(n===Mr&&(n=6),a<0?(r=0,a=-a):a>15&&(r=2,a-=16),i<1||i>$r||t!==Rn||a<8||a>15||n<0||n>9||l<0||l>Dr||a===8&&r!==1)return tt(e,Me);a===8&&(a=9);const s=new ec;return e.state=s,s.strm=e,s.status=gt,s.wrap=r,s.gzhead=null,s.w_bits=a,s.w_size=1<<s.w_bits,s.w_mask=s.w_size-1,s.hash_bits=i+7,s.hash_size=1<<s.hash_bits,s.hash_mask=s.hash_size-1,s.hash_shift=~~((s.hash_bits+j-1)/j),s.window=new Uint8Array(s.w_size*2),s.head=new Uint16Array(s.hash_size),s.prev=new Uint16Array(s.w_size),s.lit_bufsize=1<<i+6,s.pending_buf_size=s.lit_bufsize*4,s.pending_buf=new Uint8Array(s.pending_buf_size),s.sym_buf=s.lit_bufsize,s.sym_end=(s.lit_bufsize-1)*3,s.level=n,s.strategy=l,s.method=t,ha(e)},nc=(e,n)=>_a(e,n,Rn,Fr,Nr,Ur),ic=(e,n)=>{if(qt(e)||n>qi||n<0)return e?tt(e,Me):Me;const t=e.state;if(!e.output||e.avail_in!==0&&!e.input||t.status===Ct&&n!==Ie)return tt(e,e.avail_out===0?Hn:Me);const a=t.last_flush;if(t.last_flush=n,t.pending!==0){if(ye(e),e.avail_out===0)return t.last_flush=-1,ae}else if(e.avail_in===0&&eo(n)<=eo(a)&&n!==Ie)return tt(e,Hn);if(t.status===Ct&&e.avail_in!==0)return tt(e,Hn);if(t.status===gt&&t.wrap===0&&(t.status=et),t.status===gt){let i=Rn+(t.w_bits-8<<4)<<8,l=-1;if(t.strategy>=un||t.level<2?l=0:t.level<6?l=1:t.level===6?l=2:l=3,i|=l<<6,t.strstart!==0&&(i|=Kr),i+=31-i%31,It(t,i),t.strstart!==0&&(It(t,e.adler>>>16),It(t,e.adler&65535)),e.adler=1,t.status=et,ye(e),t.pending!==0)return t.last_flush=-1,ae}if(t.status===yi){if(e.adler=0,P(t,31),P(t,139),P(t,8),t.gzhead)P(t,(t.gzhead.text?1:0)+(t.gzhead.hcrc?2:0)+(t.gzhead.extra?4:0)+(t.gzhead.name?8:0)+(t.gzhead.comment?16:0)),P(t,t.gzhead.time&255),P(t,t.gzhead.time>>8&255),P(t,t.gzhead.time>>16&255),P(t,t.gzhead.time>>24&255),P(t,t.level===9?2:t.strategy>=un||t.level<2?4:0),P(t,t.gzhead.os&255),t.gzhead.extra&&t.gzhead.extra.length&&(P(t,t.gzhead.extra.length&255),P(t,t.gzhead.extra.length>>8&255)),t.gzhead.hcrc&&(e.adler=ne(e.adler,t.pending_buf,t.pending,0)),t.gzindex=0,t.status=ri;else if(P(t,0),P(t,0),P(t,0),P(t,0),P(t,0),P(t,t.level===9?2:t.strategy>=un||t.level<2?4:0),P(t,Wr),t.status=et,ye(e),t.pending!==0)return t.last_flush=-1,ae}if(t.status===ri){if(t.gzhead.extra){let i=t.pending,l=(t.gzhead.extra.length&65535)-t.gzindex;for(;t.pending+l>t.pending_buf_size;){let s=t.pending_buf_size-t.pending;if(t.pending_buf.set(t.gzhead.extra.subarray(t.gzindex,t.gzindex+s),t.pending),t.pending=t.pending_buf_size,t.gzhead.hcrc&&t.pending>i&&(e.adler=ne(e.adler,t.pending_buf,t.pending-i,i)),t.gzindex+=s,ye(e),t.pending!==0)return t.last_flush=-1,ae;i=0,l-=s}let r=new Uint8Array(t.gzhead.extra);t.pending_buf.set(r.subarray(t.gzindex,t.gzindex+l),t.pending),t.pending+=l,t.gzhead.hcrc&&t.pending>i&&(e.adler=ne(e.adler,t.pending_buf,t.pending-i,i)),t.gzindex=0}t.status=ci}if(t.status===ci){if(t.gzhead.name){let i=t.pending,l;do{if(t.pending===t.pending_buf_size){if(t.gzhead.hcrc&&t.pending>i&&(e.adler=ne(e.adler,t.pending_buf,t.pending-i,i)),ye(e),t.pending!==0)return t.last_flush=-1,ae;i=0}t.gzindex<t.gzhead.name.length?l=t.gzhead.name.charCodeAt(t.gzindex++)&255:l=0,P(t,l)}while(l!==0);t.gzhead.hcrc&&t.pending>i&&(e.adler=ne(e.adler,t.pending_buf,t.pending-i,i)),t.gzindex=0}t.status=ui}if(t.status===ui){if(t.gzhead.comment){let i=t.pending,l;do{if(t.pending===t.pending_buf_size){if(t.gzhead.hcrc&&t.pending>i&&(e.adler=ne(e.adler,t.pending_buf,t.pending-i,i)),ye(e),t.pending!==0)return t.last_flush=-1,ae;i=0}t.gzindex<t.gzhead.comment.length?l=t.gzhead.comment.charCodeAt(t.gzindex++)&255:l=0,P(t,l)}while(l!==0);t.gzhead.hcrc&&t.pending>i&&(e.adler=ne(e.adler,t.pending_buf,t.pending-i,i))}t.status=fi}if(t.status===fi){if(t.gzhead.hcrc){if(t.pending+2>t.pending_buf_size&&(ye(e),t.pending!==0))return t.last_flush=-1,ae;P(t,e.adler&255),P(t,e.adler>>8&255),e.adler=0}if(t.status=et,ye(e),t.pending!==0)return t.last_flush=-1,ae}if(e.avail_in!==0||t.lookahead!==0||n!==Ge&&t.status!==Ct){let i=t.level===0?fa(t,n):t.strategy===un?qr(t,n):t.strategy===Lr?Jr(t,n):zt[t.level].func(t,n);if((i===nt||i===kt)&&(t.status=Ct),i===_e||i===nt)return e.avail_out===0&&(t.last_flush=-1),ae;if(i===bt&&(n===Cr?Tr(t):n!==qi&&(li(t,0,0,!1),n===zr&&(Ze(t.head),t.lookahead===0&&(t.strstart=0,t.block_start=0,t.insert=0))),ye(e),e.avail_out===0))return t.last_flush=-1,ae}return n!==Ie?ae:t.wrap<=0?Xi:(t.wrap===2?(P(t,e.adler&255),P(t,e.adler>>8&255),P(t,e.adler>>16&255),P(t,e.adler>>24&255),P(t,e.total_in&255),P(t,e.total_in>>8&255),P(t,e.total_in>>16&255),P(t,e.total_in>>24&255)):(It(t,e.adler>>>16),It(t,e.adler&65535)),ye(e),t.wrap>0&&(t.wrap=-t.wrap),t.pending!==0?ae:Xi)},oc=e=>{if(qt(e))return Me;const n=e.state.status;return e.state=null,n===et?tt(e,Rr):ae},ac=(e,n)=>{let t=n.length;if(qt(e))return Me;const a=e.state,i=a.wrap;if(i===2||i===1&&a.status!==gt||a.lookahead)return Me;if(i===1&&(e.adler=jt(e.adler,n,t,0)),a.wrap=0,t>=a.w_size){i===0&&(Ze(a.head),a.strstart=0,a.block_start=0,a.insert=0);let f=new Uint8Array(a.w_size);f.set(n.subarray(t-a.w_size,t),0),n=f,t=a.w_size}const l=e.avail_in,r=e.next_in,s=e.input;for(e.avail_in=t,e.next_in=0,e.input=n,mt(a);a.lookahead>=j;){let f=a.strstart,c=a.lookahead-(j-1);do a.ins_h=Ke(a,a.ins_h,a.window[f+j-1]),a.prev[f&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=f,f++;while(--c);a.strstart=f,a.lookahead=j-1,mt(a)}return a.strstart+=a.lookahead,a.block_start=a.strstart,a.insert=a.lookahead,a.lookahead=0,a.match_length=a.prev_length=j-1,a.match_available=0,e.next_in=r,e.input=s,e.avail_in=l,a.wrap=i,ae};var lc=nc,sc=_a,rc=ha,cc=da,uc=tc,fc=ic,dc=oc,hc=ac,_c="pako deflate (from Nodeca project)",Lt={deflateInit:lc,deflateInit2:sc,deflateReset:rc,deflateResetKeep:cc,deflateSetHeader:uc,deflate:fc,deflateEnd:dc,deflateSetDictionary:hc,deflateInfo:_c};const pc=(e,n)=>Object.prototype.hasOwnProperty.call(e,n);var vc=function(e){const n=Array.prototype.slice.call(arguments,1);for(;n.length;){const t=n.shift();if(t){if(typeof t!="object")throw new TypeError(t+"must be non-object");for(const a in t)pc(t,a)&&(e[a]=t[a])}}return e},gc=e=>{let n=0;for(let a=0,i=e.length;a<i;a++)n+=e[a].length;const t=new Uint8Array(n);for(let a=0,i=0,l=e.length;a<l;a++){let r=e[a];t.set(r,i),i+=r.length}return t},Mn={assign:vc,flattenChunks:gc};let pa=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{pa=!1}const Pt=new Uint8Array(256);for(let e=0;e<256;e++)Pt[e]=e>=252?6:e>=248?5:e>=240?4:e>=224?3:e>=192?2:1;Pt[254]=Pt[254]=1;var mc=e=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(e);let n,t,a,i,l,r=e.length,s=0;for(i=0;i<r;i++)t=e.charCodeAt(i),(t&64512)===55296&&i+1<r&&(a=e.charCodeAt(i+1),(a&64512)===56320&&(t=65536+(t-55296<<10)+(a-56320),i++)),s+=t<128?1:t<2048?2:t<65536?3:4;for(n=new Uint8Array(s),l=0,i=0;l<s;i++)t=e.charCodeAt(i),(t&64512)===55296&&i+1<r&&(a=e.charCodeAt(i+1),(a&64512)===56320&&(t=65536+(t-55296<<10)+(a-56320),i++)),t<128?n[l++]=t:t<2048?(n[l++]=192|t>>>6,n[l++]=128|t&63):t<65536?(n[l++]=224|t>>>12,n[l++]=128|t>>>6&63,n[l++]=128|t&63):(n[l++]=240|t>>>18,n[l++]=128|t>>>12&63,n[l++]=128|t>>>6&63,n[l++]=128|t&63);return n};const wc=(e,n)=>{if(n<65534&&e.subarray&&pa)return String.fromCharCode.apply(null,e.length===n?e:e.subarray(0,n));let t="";for(let a=0;a<n;a++)t+=String.fromCharCode(e[a]);return t};var xc=(e,n)=>{const t=n||e.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(e.subarray(0,n));let a,i;const l=new Array(t*2);for(i=0,a=0;a<t;){let r=e[a++];if(r<128){l[i++]=r;continue}let s=Pt[r];if(s>4){l[i++]=65533,a+=s-1;continue}for(r&=s===2?31:s===3?15:7;s>1&&a<t;)r=r<<6|e[a++]&63,s--;if(s>1){l[i++]=65533;continue}r<65536?l[i++]=r:(r-=65536,l[i++]=55296|r>>10&1023,l[i++]=56320|r&1023)}return wc(l,i)},yc=(e,n)=>{n=n||e.length,n>e.length&&(n=e.length);let t=n-1;for(;t>=0&&(e[t]&192)===128;)t--;return t<0||t===0?n:t+Pt[e[t]]>n?t:n},Ht={string2buf:mc,buf2string:xc,utf8border:yc};function bc(){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 va=bc;const ga=Object.prototype.toString,{Z_NO_FLUSH:kc,Z_SYNC_FLUSH:Sc,Z_FULL_FLUSH:Ac,Z_FINISH:Ec,Z_OK:kn,Z_STREAM_END:Ic,Z_DEFAULT_COMPRESSION:Tc,Z_DEFAULT_STRATEGY:Cc,Z_DEFLATED:zc}=Jt;function bi(e){this.options=Mn.assign({level:Tc,method:zc,chunkSize:16384,windowBits:15,memLevel:8,strategy:Cc},e||{});let n=this.options;n.raw&&n.windowBits>0?n.windowBits=-n.windowBits:n.gzip&&n.windowBits>0&&n.windowBits<16&&(n.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new va,this.strm.avail_out=0;let t=Lt.deflateInit2(this.strm,n.level,n.method,n.windowBits,n.memLevel,n.strategy);if(t!==kn)throw new Error(vt[t]);if(n.header&&Lt.deflateSetHeader(this.strm,n.header),n.dictionary){let a;if(typeof n.dictionary=="string"?a=Ht.string2buf(n.dictionary):ga.call(n.dictionary)==="[object ArrayBuffer]"?a=new Uint8Array(n.dictionary):a=n.dictionary,t=Lt.deflateSetDictionary(this.strm,a),t!==kn)throw new Error(vt[t]);this._dict_set=!0}}bi.prototype.push=function(e,n){const t=this.strm,a=this.options.chunkSize;let i,l;if(this.ended)return!1;for(n===~~n?l=n:l=n===!0?Ec:kc,typeof e=="string"?t.input=Ht.string2buf(e):ga.call(e)==="[object ArrayBuffer]"?t.input=new Uint8Array(e):t.input=e,t.next_in=0,t.avail_in=t.input.length;;){if(t.avail_out===0&&(t.output=new Uint8Array(a),t.next_out=0,t.avail_out=a),(l===Sc||l===Ac)&&t.avail_out<=6){this.onData(t.output.subarray(0,t.next_out)),t.avail_out=0;continue}if(i=Lt.deflate(t,l),i===Ic)return t.next_out>0&&this.onData(t.output.subarray(0,t.next_out)),i=Lt.deflateEnd(this.strm),this.onEnd(i),this.ended=!0,i===kn;if(t.avail_out===0){this.onData(t.output);continue}if(l>0&&t.next_out>0){this.onData(t.output.subarray(0,t.next_out)),t.avail_out=0;continue}if(t.avail_in===0)break}return!0};bi.prototype.onData=function(e){this.chunks.push(e)};bi.prototype.onEnd=function(e){e===kn&&(this.result=Mn.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};const fn=16209,Rc=16191;var Mc=function(n,t){let a,i,l,r,s,f,c,u,h,d,w,I,L,E,k,M,S,b,x,p,_,g,$,B;const O=n.state;a=n.next_in,$=n.input,i=a+(n.avail_in-5),l=n.next_out,B=n.output,r=l-(t-n.avail_out),s=l+(n.avail_out-257),f=O.dmax,c=O.wsize,u=O.whave,h=O.wnext,d=O.window,w=O.hold,I=O.bits,L=O.lencode,E=O.distcode,k=(1<<O.lenbits)-1,M=(1<<O.distbits)-1;e:do{I<15&&(w+=$[a++]<<I,I+=8,w+=$[a++]<<I,I+=8),S=L[w&k];t:for(;;){if(b=S>>>24,w>>>=b,I-=b,b=S>>>16&255,b===0)B[l++]=S&65535;else if(b&16){x=S&65535,b&=15,b&&(I<b&&(w+=$[a++]<<I,I+=8),x+=w&(1<<b)-1,w>>>=b,I-=b),I<15&&(w+=$[a++]<<I,I+=8,w+=$[a++]<<I,I+=8),S=E[w&M];n:for(;;){if(b=S>>>24,w>>>=b,I-=b,b=S>>>16&255,b&16){if(p=S&65535,b&=15,I<b&&(w+=$[a++]<<I,I+=8,I<b&&(w+=$[a++]<<I,I+=8)),p+=w&(1<<b)-1,p>f){n.msg="invalid distance too far back",O.mode=fn;break e}if(w>>>=b,I-=b,b=l-r,p>b){if(b=p-b,b>u&&O.sane){n.msg="invalid distance too far back",O.mode=fn;break e}if(_=0,g=d,h===0){if(_+=c-b,b<x){x-=b;do B[l++]=d[_++];while(--b);_=l-p,g=B}}else if(h<b){if(_+=c+h-b,b-=h,b<x){x-=b;do B[l++]=d[_++];while(--b);if(_=0,h<x){b=h,x-=b;do B[l++]=d[_++];while(--b);_=l-p,g=B}}}else if(_+=h-b,b<x){x-=b;do B[l++]=d[_++];while(--b);_=l-p,g=B}for(;x>2;)B[l++]=g[_++],B[l++]=g[_++],B[l++]=g[_++],x-=3;x&&(B[l++]=g[_++],x>1&&(B[l++]=g[_++]))}else{_=l-p;do B[l++]=B[_++],B[l++]=B[_++],B[l++]=B[_++],x-=3;while(x>2);x&&(B[l++]=B[_++],x>1&&(B[l++]=B[_++]))}}else if(b&64){n.msg="invalid distance code",O.mode=fn;break e}else{S=E[(S&65535)+(w&(1<<b)-1)];continue n}break}}else if(b&64)if(b&32){O.mode=Rc;break e}else{n.msg="invalid literal/length code",O.mode=fn;break e}else{S=L[(S&65535)+(w&(1<<b)-1)];continue t}break}}while(a<i&&l<s);x=I>>3,a-=x,I-=x<<3,w&=(1<<I)-1,n.next_in=a,n.next_out=l,n.avail_in=a<i?5+(i-a):5-(a-i),n.avail_out=l<s?257+(s-l):257-(l-s),O.hold=w,O.bits=I};const ut=15,to=852,no=592,io=0,Gn=1,oo=2,Oc=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]),Lc=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]),Dc=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]),Uc=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]),Bc=(e,n,t,a,i,l,r,s)=>{const f=s.bits;let c=0,u=0,h=0,d=0,w=0,I=0,L=0,E=0,k=0,M=0,S,b,x,p,_,g=null,$;const B=new Uint16Array(ut+1),O=new Uint16Array(ut+1);let me=null,Fe,at,se;for(c=0;c<=ut;c++)B[c]=0;for(u=0;u<a;u++)B[n[t+u]]++;for(w=f,d=ut;d>=1&&B[d]===0;d--);if(w>d&&(w=d),d===0)return i[l++]=1<<24|64<<16|0,i[l++]=1<<24|64<<16|0,s.bits=1,0;for(h=1;h<d&&B[h]===0;h++);for(w<h&&(w=h),E=1,c=1;c<=ut;c++)if(E<<=1,E-=B[c],E<0)return-1;if(E>0&&(e===io||d!==1))return-1;for(O[1]=0,c=1;c<ut;c++)O[c+1]=O[c]+B[c];for(u=0;u<a;u++)n[t+u]!==0&&(r[O[n[t+u]]++]=u);if(e===io?(g=me=r,$=20):e===Gn?(g=Oc,me=Lc,$=257):(g=Dc,me=Uc,$=0),M=0,u=0,c=h,_=l,I=w,L=0,x=-1,k=1<<w,p=k-1,e===Gn&&k>to||e===oo&&k>no)return 1;for(;;){Fe=c-L,r[u]+1<$?(at=0,se=r[u]):r[u]>=$?(at=me[r[u]-$],se=g[r[u]-$]):(at=96,se=0),S=1<<c-L,b=1<<I,h=b;do b-=S,i[_+(M>>L)+b]=Fe<<24|at<<16|se|0;while(b!==0);for(S=1<<c-1;M&S;)S>>=1;if(S!==0?(M&=S-1,M+=S):M=0,u++,--B[c]===0){if(c===d)break;c=n[t+r[u]]}if(c>w&&(M&p)!==x){for(L===0&&(L=w),_+=h,I=c-L,E=1<<I;I+L<d&&(E-=B[I+L],!(E<=0));)I++,E<<=1;if(k+=1<<I,e===Gn&&k>to||e===oo&&k>no)return 1;x=M&p,i[x]=w<<24|I<<16|_-l|0}}return M!==0&&(i[_+M]=c-L<<24|64<<16|0),s.bits=w,0};var Dt=Bc;const $c=0,ma=1,wa=2,{Z_FINISH:ao,Z_BLOCK:Fc,Z_TREES:dn,Z_OK:it,Z_STREAM_END:Nc,Z_NEED_DICT:Zc,Z_STREAM_ERROR:Te,Z_DATA_ERROR:xa,Z_MEM_ERROR:ya,Z_BUF_ERROR:jc,Z_DEFLATED:lo}=Jt,On=16180,so=16181,ro=16182,co=16183,uo=16184,fo=16185,ho=16186,_o=16187,po=16188,vo=16189,Sn=16190,Ue=16191,Kn=16192,go=16193,Wn=16194,mo=16195,wo=16196,xo=16197,yo=16198,hn=16199,_n=16200,bo=16201,ko=16202,So=16203,Ao=16204,Eo=16205,Yn=16206,Io=16207,To=16208,G=16209,ba=16210,ka=16211,Pc=852,Hc=592,Vc=15,Gc=Vc,Co=e=>(e>>>24&255)+(e>>>8&65280)+((e&65280)<<8)+((e&255)<<24);function Kc(){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 ot=e=>{if(!e)return 1;const n=e.state;return!n||n.strm!==e||n.mode<On||n.mode>ka?1:0},Sa=e=>{if(ot(e))return Te;const n=e.state;return e.total_in=e.total_out=n.total=0,e.msg="",n.wrap&&(e.adler=n.wrap&1),n.mode=On,n.last=0,n.havedict=0,n.flags=-1,n.dmax=32768,n.head=null,n.hold=0,n.bits=0,n.lencode=n.lendyn=new Int32Array(Pc),n.distcode=n.distdyn=new Int32Array(Hc),n.sane=1,n.back=-1,it},Aa=e=>{if(ot(e))return Te;const n=e.state;return n.wsize=0,n.whave=0,n.wnext=0,Sa(e)},Ea=(e,n)=>{let t;if(ot(e))return Te;const a=e.state;return n<0?(t=0,n=-n):(t=(n>>4)+5,n<48&&(n&=15)),n&&(n<8||n>15)?Te:(a.window!==null&&a.wbits!==n&&(a.window=null),a.wrap=t,a.wbits=n,Aa(e))},Ia=(e,n)=>{if(!e)return Te;const t=new Kc;e.state=t,t.strm=e,t.window=null,t.mode=On;const a=Ea(e,n);return a!==it&&(e.state=null),a},Wc=e=>Ia(e,Gc);let zo=!0,Qn,Jn;const Yc=e=>{if(zo){Qn=new Int32Array(512),Jn=new Int32Array(32);let n=0;for(;n<144;)e.lens[n++]=8;for(;n<256;)e.lens[n++]=9;for(;n<280;)e.lens[n++]=7;for(;n<288;)e.lens[n++]=8;for(Dt(ma,e.lens,0,288,Qn,0,e.work,{bits:9}),n=0;n<32;)e.lens[n++]=5;Dt(wa,e.lens,0,32,Jn,0,e.work,{bits:5}),zo=!1}e.lencode=Qn,e.lenbits=9,e.distcode=Jn,e.distbits=5},Ta=(e,n,t,a)=>{let i;const l=e.state;return l.window===null&&(l.wsize=1<<l.wbits,l.wnext=0,l.whave=0,l.window=new Uint8Array(l.wsize)),a>=l.wsize?(l.window.set(n.subarray(t-l.wsize,t),0),l.wnext=0,l.whave=l.wsize):(i=l.wsize-l.wnext,i>a&&(i=a),l.window.set(n.subarray(t-a,t-a+i),l.wnext),a-=i,a?(l.window.set(n.subarray(t-a,t),0),l.wnext=a,l.whave=l.wsize):(l.wnext+=i,l.wnext===l.wsize&&(l.wnext=0),l.whave<l.wsize&&(l.whave+=i))),0},Qc=(e,n)=>{let t,a,i,l,r,s,f,c,u,h,d,w,I,L,E=0,k,M,S,b,x,p,_,g;const $=new Uint8Array(4);let B,O;const me=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(ot(e)||!e.output||!e.input&&e.avail_in!==0)return Te;t=e.state,t.mode===Ue&&(t.mode=Kn),r=e.next_out,i=e.output,f=e.avail_out,l=e.next_in,a=e.input,s=e.avail_in,c=t.hold,u=t.bits,h=s,d=f,g=it;e:for(;;)switch(t.mode){case On:if(t.wrap===0){t.mode=Kn;break}for(;u<16;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(t.wrap&2&&c===35615){t.wbits===0&&(t.wbits=15),t.check=0,$[0]=c&255,$[1]=c>>>8&255,t.check=ne(t.check,$,2,0),c=0,u=0,t.mode=so;break}if(t.head&&(t.head.done=!1),!(t.wrap&1)||(((c&255)<<8)+(c>>8))%31){e.msg="incorrect header check",t.mode=G;break}if((c&15)!==lo){e.msg="unknown compression method",t.mode=G;break}if(c>>>=4,u-=4,_=(c&15)+8,t.wbits===0&&(t.wbits=_),_>15||_>t.wbits){e.msg="invalid window size",t.mode=G;break}t.dmax=1<<t.wbits,t.flags=0,e.adler=t.check=1,t.mode=c&512?vo:Ue,c=0,u=0;break;case so:for(;u<16;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(t.flags=c,(t.flags&255)!==lo){e.msg="unknown compression method",t.mode=G;break}if(t.flags&57344){e.msg="unknown header flags set",t.mode=G;break}t.head&&(t.head.text=c>>8&1),t.flags&512&&t.wrap&4&&($[0]=c&255,$[1]=c>>>8&255,t.check=ne(t.check,$,2,0)),c=0,u=0,t.mode=ro;case ro:for(;u<32;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}t.head&&(t.head.time=c),t.flags&512&&t.wrap&4&&($[0]=c&255,$[1]=c>>>8&255,$[2]=c>>>16&255,$[3]=c>>>24&255,t.check=ne(t.check,$,4,0)),c=0,u=0,t.mode=co;case co:for(;u<16;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}t.head&&(t.head.xflags=c&255,t.head.os=c>>8),t.flags&512&&t.wrap&4&&($[0]=c&255,$[1]=c>>>8&255,t.check=ne(t.check,$,2,0)),c=0,u=0,t.mode=uo;case uo:if(t.flags&1024){for(;u<16;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}t.length=c,t.head&&(t.head.extra_len=c),t.flags&512&&t.wrap&4&&($[0]=c&255,$[1]=c>>>8&255,t.check=ne(t.check,$,2,0)),c=0,u=0}else t.head&&(t.head.extra=null);t.mode=fo;case fo:if(t.flags&1024&&(w=t.length,w>s&&(w=s),w&&(t.head&&(_=t.head.extra_len-t.length,t.head.extra||(t.head.extra=new Uint8Array(t.head.extra_len)),t.head.extra.set(a.subarray(l,l+w),_)),t.flags&512&&t.wrap&4&&(t.check=ne(t.check,a,w,l)),s-=w,l+=w,t.length-=w),t.length))break e;t.length=0,t.mode=ho;case ho:if(t.flags&2048){if(s===0)break e;w=0;do _=a[l+w++],t.head&&_&&t.length<65536&&(t.head.name+=String.fromCharCode(_));while(_&&w<s);if(t.flags&512&&t.wrap&4&&(t.check=ne(t.check,a,w,l)),s-=w,l+=w,_)break e}else t.head&&(t.head.name=null);t.length=0,t.mode=_o;case _o:if(t.flags&4096){if(s===0)break e;w=0;do _=a[l+w++],t.head&&_&&t.length<65536&&(t.head.comment+=String.fromCharCode(_));while(_&&w<s);if(t.flags&512&&t.wrap&4&&(t.check=ne(t.check,a,w,l)),s-=w,l+=w,_)break e}else t.head&&(t.head.comment=null);t.mode=po;case po:if(t.flags&512){for(;u<16;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(t.wrap&4&&c!==(t.check&65535)){e.msg="header crc mismatch",t.mode=G;break}c=0,u=0}t.head&&(t.head.hcrc=t.flags>>9&1,t.head.done=!0),e.adler=t.check=0,t.mode=Ue;break;case vo:for(;u<32;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}e.adler=t.check=Co(c),c=0,u=0,t.mode=Sn;case Sn:if(t.havedict===0)return e.next_out=r,e.avail_out=f,e.next_in=l,e.avail_in=s,t.hold=c,t.bits=u,Zc;e.adler=t.check=1,t.mode=Ue;case Ue:if(n===Fc||n===dn)break e;case Kn:if(t.last){c>>>=u&7,u-=u&7,t.mode=Yn;break}for(;u<3;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}switch(t.last=c&1,c>>>=1,u-=1,c&3){case 0:t.mode=go;break;case 1:if(Yc(t),t.mode=hn,n===dn){c>>>=2,u-=2;break e}break;case 2:t.mode=wo;break;case 3:e.msg="invalid block type",t.mode=G}c>>>=2,u-=2;break;case go:for(c>>>=u&7,u-=u&7;u<32;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if((c&65535)!==(c>>>16^65535)){e.msg="invalid stored block lengths",t.mode=G;break}if(t.length=c&65535,c=0,u=0,t.mode=Wn,n===dn)break e;case Wn:t.mode=mo;case mo:if(w=t.length,w){if(w>s&&(w=s),w>f&&(w=f),w===0)break e;i.set(a.subarray(l,l+w),r),s-=w,l+=w,f-=w,r+=w,t.length-=w;break}t.mode=Ue;break;case wo:for(;u<14;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(t.nlen=(c&31)+257,c>>>=5,u-=5,t.ndist=(c&31)+1,c>>>=5,u-=5,t.ncode=(c&15)+4,c>>>=4,u-=4,t.nlen>286||t.ndist>30){e.msg="too many length or distance symbols",t.mode=G;break}t.have=0,t.mode=xo;case xo:for(;t.have<t.ncode;){for(;u<3;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}t.lens[me[t.have++]]=c&7,c>>>=3,u-=3}for(;t.have<19;)t.lens[me[t.have++]]=0;if(t.lencode=t.lendyn,t.lenbits=7,B={bits:t.lenbits},g=Dt($c,t.lens,0,19,t.lencode,0,t.work,B),t.lenbits=B.bits,g){e.msg="invalid code lengths set",t.mode=G;break}t.have=0,t.mode=yo;case yo:for(;t.have<t.nlen+t.ndist;){for(;E=t.lencode[c&(1<<t.lenbits)-1],k=E>>>24,M=E>>>16&255,S=E&65535,!(k<=u);){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(S<16)c>>>=k,u-=k,t.lens[t.have++]=S;else{if(S===16){for(O=k+2;u<O;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(c>>>=k,u-=k,t.have===0){e.msg="invalid bit length repeat",t.mode=G;break}_=t.lens[t.have-1],w=3+(c&3),c>>>=2,u-=2}else if(S===17){for(O=k+3;u<O;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}c>>>=k,u-=k,_=0,w=3+(c&7),c>>>=3,u-=3}else{for(O=k+7;u<O;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}c>>>=k,u-=k,_=0,w=11+(c&127),c>>>=7,u-=7}if(t.have+w>t.nlen+t.ndist){e.msg="invalid bit length repeat",t.mode=G;break}for(;w--;)t.lens[t.have++]=_}}if(t.mode===G)break;if(t.lens[256]===0){e.msg="invalid code -- missing end-of-block",t.mode=G;break}if(t.lenbits=9,B={bits:t.lenbits},g=Dt(ma,t.lens,0,t.nlen,t.lencode,0,t.work,B),t.lenbits=B.bits,g){e.msg="invalid literal/lengths set",t.mode=G;break}if(t.distbits=6,t.distcode=t.distdyn,B={bits:t.distbits},g=Dt(wa,t.lens,t.nlen,t.ndist,t.distcode,0,t.work,B),t.distbits=B.bits,g){e.msg="invalid distances set",t.mode=G;break}if(t.mode=hn,n===dn)break e;case hn:t.mode=_n;case _n:if(s>=6&&f>=258){e.next_out=r,e.avail_out=f,e.next_in=l,e.avail_in=s,t.hold=c,t.bits=u,Mc(e,d),r=e.next_out,i=e.output,f=e.avail_out,l=e.next_in,a=e.input,s=e.avail_in,c=t.hold,u=t.bits,t.mode===Ue&&(t.back=-1);break}for(t.back=0;E=t.lencode[c&(1<<t.lenbits)-1],k=E>>>24,M=E>>>16&255,S=E&65535,!(k<=u);){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(M&&!(M&240)){for(b=k,x=M,p=S;E=t.lencode[p+((c&(1<<b+x)-1)>>b)],k=E>>>24,M=E>>>16&255,S=E&65535,!(b+k<=u);){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}c>>>=b,u-=b,t.back+=b}if(c>>>=k,u-=k,t.back+=k,t.length=S,M===0){t.mode=Eo;break}if(M&32){t.back=-1,t.mode=Ue;break}if(M&64){e.msg="invalid literal/length code",t.mode=G;break}t.extra=M&15,t.mode=bo;case bo:if(t.extra){for(O=t.extra;u<O;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}t.length+=c&(1<<t.extra)-1,c>>>=t.extra,u-=t.extra,t.back+=t.extra}t.was=t.length,t.mode=ko;case ko:for(;E=t.distcode[c&(1<<t.distbits)-1],k=E>>>24,M=E>>>16&255,S=E&65535,!(k<=u);){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(!(M&240)){for(b=k,x=M,p=S;E=t.distcode[p+((c&(1<<b+x)-1)>>b)],k=E>>>24,M=E>>>16&255,S=E&65535,!(b+k<=u);){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}c>>>=b,u-=b,t.back+=b}if(c>>>=k,u-=k,t.back+=k,M&64){e.msg="invalid distance code",t.mode=G;break}t.offset=S,t.extra=M&15,t.mode=So;case So:if(t.extra){for(O=t.extra;u<O;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}t.offset+=c&(1<<t.extra)-1,c>>>=t.extra,u-=t.extra,t.back+=t.extra}if(t.offset>t.dmax){e.msg="invalid distance too far back",t.mode=G;break}t.mode=Ao;case Ao:if(f===0)break e;if(w=d-f,t.offset>w){if(w=t.offset-w,w>t.whave&&t.sane){e.msg="invalid distance too far back",t.mode=G;break}w>t.wnext?(w-=t.wnext,I=t.wsize-w):I=t.wnext-w,w>t.length&&(w=t.length),L=t.window}else L=i,I=r-t.offset,w=t.length;w>f&&(w=f),f-=w,t.length-=w;do i[r++]=L[I++];while(--w);t.length===0&&(t.mode=_n);break;case Eo:if(f===0)break e;i[r++]=t.length,f--,t.mode=_n;break;case Yn:if(t.wrap){for(;u<32;){if(s===0)break e;s--,c|=a[l++]<<u,u+=8}if(d-=f,e.total_out+=d,t.total+=d,t.wrap&4&&d&&(e.adler=t.check=t.flags?ne(t.check,i,d,r-d):jt(t.check,i,d,r-d)),d=f,t.wrap&4&&(t.flags?c:Co(c))!==t.check){e.msg="incorrect data check",t.mode=G;break}c=0,u=0}t.mode=Io;case Io:if(t.wrap&&t.flags){for(;u<32;){if(s===0)break e;s--,c+=a[l++]<<u,u+=8}if(t.wrap&4&&c!==(t.total&4294967295)){e.msg="incorrect length check",t.mode=G;break}c=0,u=0}t.mode=To;case To:g=Nc;break e;case G:g=xa;break e;case ba:return ya;case ka:default:return Te}return e.next_out=r,e.avail_out=f,e.next_in=l,e.avail_in=s,t.hold=c,t.bits=u,(t.wsize||d!==e.avail_out&&t.mode<G&&(t.mode<Yn||n!==ao))&&Ta(e,e.output,e.next_out,d-e.avail_out),h-=e.avail_in,d-=e.avail_out,e.total_in+=h,e.total_out+=d,t.total+=d,t.wrap&4&&d&&(e.adler=t.check=t.flags?ne(t.check,i,d,e.next_out-d):jt(t.check,i,d,e.next_out-d)),e.data_type=t.bits+(t.last?64:0)+(t.mode===Ue?128:0)+(t.mode===hn||t.mode===Wn?256:0),(h===0&&d===0||n===ao)&&g===it&&(g=jc),g},Jc=e=>{if(ot(e))return Te;let n=e.state;return n.window&&(n.window=null),e.state=null,it},qc=(e,n)=>{if(ot(e))return Te;const t=e.state;return t.wrap&2?(t.head=n,n.done=!1,it):Te},Xc=(e,n)=>{const t=n.length;let a,i,l;return ot(e)||(a=e.state,a.wrap!==0&&a.mode!==Sn)?Te:a.mode===Sn&&(i=1,i=jt(i,n,t,0),i!==a.check)?xa:(l=Ta(e,n,t,t),l?(a.mode=ba,ya):(a.havedict=1,it))};var eu=Aa,tu=Ea,nu=Sa,iu=Wc,ou=Ia,au=Qc,lu=Jc,su=qc,ru=Xc,cu="pako inflate (from Nodeca project)",$e={inflateReset:eu,inflateReset2:tu,inflateResetKeep:nu,inflateInit:iu,inflateInit2:ou,inflate:au,inflateEnd:lu,inflateGetHeader:su,inflateSetDictionary:ru,inflateInfo:cu};function uu(){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 fu=uu;const Ca=Object.prototype.toString,{Z_NO_FLUSH:du,Z_FINISH:hu,Z_OK:Vt,Z_STREAM_END:qn,Z_NEED_DICT:Xn,Z_STREAM_ERROR:_u,Z_DATA_ERROR:Ro,Z_MEM_ERROR:pu}=Jt;function Xt(e){this.options=Mn.assign({chunkSize:1024*64,windowBits:15,to:""},e||{});const n=this.options;n.raw&&n.windowBits>=0&&n.windowBits<16&&(n.windowBits=-n.windowBits,n.windowBits===0&&(n.windowBits=-15)),n.windowBits>=0&&n.windowBits<16&&!(e&&e.windowBits)&&(n.windowBits+=32),n.windowBits>15&&n.windowBits<48&&(n.windowBits&15||(n.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new va,this.strm.avail_out=0;let t=$e.inflateInit2(this.strm,n.windowBits);if(t!==Vt)throw new Error(vt[t]);if(this.header=new fu,$e.inflateGetHeader(this.strm,this.header),n.dictionary&&(typeof n.dictionary=="string"?n.dictionary=Ht.string2buf(n.dictionary):Ca.call(n.dictionary)==="[object ArrayBuffer]"&&(n.dictionary=new Uint8Array(n.dictionary)),n.raw&&(t=$e.inflateSetDictionary(this.strm,n.dictionary),t!==Vt)))throw new Error(vt[t])}Xt.prototype.push=function(e,n){const t=this.strm,a=this.options.chunkSize,i=this.options.dictionary;let l,r,s;if(this.ended)return!1;for(n===~~n?r=n:r=n===!0?hu:du,Ca.call(e)==="[object ArrayBuffer]"?t.input=new Uint8Array(e):t.input=e,t.next_in=0,t.avail_in=t.input.length;;){for(t.avail_out===0&&(t.output=new Uint8Array(a),t.next_out=0,t.avail_out=a),l=$e.inflate(t,r),l===Xn&&i&&(l=$e.inflateSetDictionary(t,i),l===Vt?l=$e.inflate(t,r):l===Ro&&(l=Xn));t.avail_in>0&&l===qn&&t.state.wrap>0&&e[t.next_in]!==0;)$e.inflateReset(t),l=$e.inflate(t,r);switch(l){case _u:case Ro:case Xn:case pu:return this.onEnd(l),this.ended=!0,!1}if(s=t.avail_out,t.next_out&&(t.avail_out===0||l===qn))if(this.options.to==="string"){let f=Ht.utf8border(t.output,t.next_out),c=t.next_out-f,u=Ht.buf2string(t.output,f);t.next_out=c,t.avail_out=a-c,c&&t.output.set(t.output.subarray(f,f+c),0),this.onData(u)}else this.onData(t.output.length===t.next_out?t.output:t.output.subarray(0,t.next_out));if(!(l===Vt&&s===0)){if(l===qn)return l=$e.inflateEnd(this.strm),this.onEnd(l),this.ended=!0,!0;if(t.avail_in===0)break}}return!0};Xt.prototype.onData=function(e){this.chunks.push(e)};Xt.prototype.onEnd=function(e){e===Vt&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Mn.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function ki(e,n){const t=new Xt(n);if(t.push(e),t.err)throw t.msg||vt[t.err];return t.result}function vu(e,n){return n=n||{},n.raw=!0,ki(e,n)}var gu=Xt,mu=ki,wu=vu,xu=ki,yu=Jt,bu={Inflate:gu,inflate:mu,inflateRaw:wu,ungzip:xu,constants:yu};const{Inflate:ed,inflate:td,inflateRaw:nd,ungzip:ku}=bu;var Su=ku;function Au(e){return Eu(Ai(e))}function Eu(e){let n={};e:for(;!At(e);){let t=ee(e);switch(t>>>3){case 0:break e;case 1:{let a=Si(e);(n.messagesList||(n.messagesList=[])).push(Iu(e)),e.limit=a;break}case 8:{n.heartbeatDuration=He(e,!0);break}case 9:{n.needAck=!!pe(e);break}default:St(e,t&7)}}return n}function Iu(e){let n={};e:for(;!At(e);){let t=ee(e);switch(t>>>3){case 0:break e;case 1:{n.method=Qe(e,ee(e));break}case 2:{n.payload=Ma(e,ee(e));break}case 3:{n.msgId=He(e,!1);break}case 4:{n.msgType=ee(e);break}case 5:{n.offset=He(e,!1);break}case 6:{n.needWrdsStore=!!pe(e);break}case 7:{n.wrdsVersion=He(e,!1);break}case 8:{n.wrdsSubKey=Qe(e,ee(e));break}default:St(e,t&7)}}return n}function Tu(e){return Cu(Ai(e))}function Cu(e){let n={};e:for(;!At(e);){let t=ee(e);switch(t>>>3){case 0:break e;case 2:{let a=Si(e);n.user=zu(e),e.limit=a;break}case 3:{n.content=Qe(e,ee(e));break}default:St(e,t&7)}}return n}function zu(e){let n={};e:for(;!At(e);){let t=ee(e);switch(t>>>3){case 0:break e;case 3:{n.nickName=Qe(e,ee(e));break}default:St(e,t&7)}}return n}function Ru(e){let n=Ra();return Mu(e,n),Nu(n)}function Mu(e,n){let t=e.seqId;t!==void 0&&(be(n,8),pn(n,t));let a=e.logId;a!==void 0&&(be(n,16),pn(n,a));let i=e.service;i!==void 0&&(be(n,24),pn(n,i));let l=e.method;l!==void 0&&(be(n,32),pn(n,l));let r=e.headersList;if(r!==void 0)for(let u of r){be(n,42);let h=Ra();Du(u,h),be(n,h.limit),ju(n,h),Fu(h)}let s=e.payloadEncoding;s!==void 0&&(be(n,50),An(n,s));let f=e.payloadType;f!==void 0&&(be(n,58),An(n,f));let c=e.payload;c!==void 0&&(be(n,66),be(n,c.length),Zu(n,c))}function Ou(e){return Lu(Ai(e))}function Lu(e){let n={};e:for(;!At(e);){let t=ee(e);switch(t>>>3){case 0:break e;case 1:{n.seqId=He(e,!0);break}case 2:{n.logId=He(e,!0);break}case 3:{n.service=He(e,!0);break}case 4:{n.method=He(e,!0);break}case 5:{let a=Si(e);(n.headersList||(n.headersList=[])).push(Uu(e)),e.limit=a;break}case 6:{n.payloadEncoding=Qe(e,ee(e));break}case 7:{n.payloadType=Qe(e,ee(e));break}case 8:{n.payload=Ma(e,ee(e));break}default:St(e,t&7)}}return n}function Du(e,n){let t=e.key;t!==void 0&&(be(n,10),An(n,t));let a=e.value;a!==void 0&&(be(n,18),An(n,a))}function Uu(e){let n={};e:for(;!At(e);){let t=ee(e);switch(t>>>3){case 0:break e;case 1:{n.key=Qe(e,ee(e));break}case 2:{n.value=Qe(e,ee(e));break}default:St(e,t&7)}}return n}function Si(e){let n=ee(e),t=e.limit;return e.limit=e.offset+n,t}function St(e,n){switch(n){case 0:for(;pe(e)&128;);break;case 2:ei(e,ee(e));break;case 5:ei(e,4);break;case 1:ei(e,8);break;default:throw new Error("Unimplemented type: "+n)}}let Bu=new Float32Array(1);new Uint8Array(Bu.buffer);let $u=new Float64Array(1);new Uint8Array($u.buffer);let za=[];function Ra(){const e=za.pop();return e?(e.offset=e.limit=0,e):{bytes:new Uint8Array(64),offset:0,limit:0}}function Fu(e){za.push(e)}function Ai(e){return{bytes:e,offset:0,limit:e.length}}function Nu(e){let n=e.bytes,t=e.limit;return n.length===t?n:n.subarray(0,t)}function ei(e,n){if(e.offset+n>e.limit)throw new Error("Skip past limit");e.offset+=n}function At(e){return e.offset>=e.limit}function en(e,n){let t=e.bytes,a=e.offset,i=e.limit,l=a+n;if(l>t.length){let r=new Uint8Array(l*2);r.set(t),e.bytes=r}return e.offset=l,l>i&&(e.limit=l),a}function Ei(e,n){let t=e.offset;if(t+n>e.limit)throw new Error("Read past limit");return e.offset+=n,t}function Ma(e,n){let t=Ei(e,n);return e.bytes.subarray(t,t+n)}function Zu(e,n){let t=en(e,n.length);e.bytes.set(n,t)}function Qe(e,n){let t=Ei(e,n),a=String.fromCharCode,i=e.bytes,l="�",r="";for(let s=0;s<n;s++){let f=i[s+t],c,u,h,d;f&128?(f&224)===192?s+1>=n?r+=l:(c=i[s+t+1],(c&192)!==128?r+=l:(d=(f&31)<<6|c&63,d<128?r+=l:(r+=a(d),s++))):(f&240)==224?s+2>=n?r+=l:(c=i[s+t+1],u=i[s+t+2],((c|u<<8)&49344)!==32896?r+=l:(d=(f&15)<<12|(c&63)<<6|u&63,d<2048||d>=55296&&d<=57343?r+=l:(r+=a(d),s+=2))):(f&248)==240?s+3>=n?r+=l:(c=i[s+t+1],u=i[s+t+2],h=i[s+t+3],((c|u<<8|h<<16)&12632256)!==8421504?r+=l:(d=(f&7)<<18|(c&63)<<12|(u&63)<<6|h&63,d<65536||d>1114111?r+=l:(d-=65536,r+=a((d>>10)+55296,(d&1023)+56320),s+=3))):r+=l:r+=a(f)}return r}function An(e,n){let t=n.length,a=0;for(let r=0;r<t;r++){let s=n.charCodeAt(r);s>=55296&&s<=56319&&r+1<t&&(s=(s<<10)+n.charCodeAt(++r)-56613888),a+=s<128?1:s<2048?2:s<65536?3:4}be(e,a);let i=en(e,a),l=e.bytes;for(let r=0;r<t;r++){let s=n.charCodeAt(r);s>=55296&&s<=56319&&r+1<t&&(s=(s<<10)+n.charCodeAt(++r)-56613888),s<128?l[i++]=s:(s<2048?l[i++]=s>>6&31|192:(s<65536?l[i++]=s>>12&15|224:(l[i++]=s>>18&7|240,l[i++]=s>>12&63|128),l[i++]=s>>6&63|128),l[i++]=s&63|128)}}function ju(e,n){let t=en(e,n.limit),a=e.bytes,i=n.bytes;for(let l=0,r=n.limit;l<r;l++)a[l+t]=i[l]}function pe(e){return e.bytes[Ei(e,1)]}function Mo(e,n){let t=en(e,1);e.bytes[t]=n}function ee(e){let n=0,t=0,a;do a=pe(e),n<32&&(t|=(a&127)<<n),n+=7;while(a&128);return t}function be(e,n){for(n>>>=0;n>=128;)Mo(e,n&127|128),n>>>=7;Mo(e,n)}function He(e,n){let t=0,a=0,i=0,l;return l=pe(e),t=l&127,l&128&&(l=pe(e),t|=(l&127)<<7,l&128&&(l=pe(e),t|=(l&127)<<14,l&128&&(l=pe(e),t|=(l&127)<<21,l&128&&(l=pe(e),a=l&127,l&128&&(l=pe(e),a|=(l&127)<<7,l&128&&(l=pe(e),a|=(l&127)<<14,l&128&&(l=pe(e),a|=(l&127)<<21,l&128&&(l=pe(e),i=l&127,l&128&&(l=pe(e),i|=(l&127)<<7))))))))),{low:t|a<<28,high:a>>>4|i<<24,unsigned:n}}function pn(e,n){let t=n.low>>>0,a=(n.low>>>28|n.high<<4)>>>0,i=n.high>>>24,l=i===0?a===0?t<16384?t<128?1:2:t<1<<21?3:4:a<16384?a<128?5:6:a<1<<21?7:8:i<128?9:10,r=en(e,l),s=e.bytes;switch(l){case 10:s[r+9]=i>>>7&1;case 9:s[r+8]=l!==9?i|128:i&127;case 8:s[r+7]=l!==8?a>>>21|128:a>>>21&127;case 7:s[r+6]=l!==7?a>>>14|128:a>>>14&127;case 6:s[r+5]=l!==6?a>>>7|128:a>>>7&127;case 5:s[r+4]=l!==5?a|128:a&127;case 4:s[r+3]=l!==4?t>>>21|128:t>>>21&127;case 3:s[r+2]=l!==3?t>>>14|128:t>>>14&127;case 2:s[r+1]=l!==2?t>>>7|128:t>>>7&127;case 1:s[r]=l!==1?t|128:t&127}}var Pu=function(e,n){e.constructor==String?e=Wu(e):o(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var t=Yu(e),a=8*e.length,i=1732584193,l=-271733879,r=-1732584194,s=271733878,f=0;f<t.length;f++)t[f]=(t[f]<<8|t[f]>>>24)&16711935|(t[f]<<24|t[f]>>>8)&4278255360;t[a>>>5]|=128<<a%32,t[(a+64>>>9<<4)+14]=a;for(var c=Hu,u=Vu,h=Gu,d=Ku,f=0;f<t.length;f+=16){var w=i,I=l,L=r,E=s;i=c(i,l,r,s,t[f+0],7,-680876936),s=c(s,i,l,r,t[f+1],12,-389564586),r=c(r,s,i,l,t[f+2],17,606105819),l=c(l,r,s,i,t[f+3],22,-1044525330),i=c(i,l,r,s,t[f+4],7,-176418897),s=c(s,i,l,r,t[f+5],12,1200080426),r=c(r,s,i,l,t[f+6],17,-1473231341),l=c(l,r,s,i,t[f+7],22,-45705983),i=c(i,l,r,s,t[f+8],7,1770035416),s=c(s,i,l,r,t[f+9],12,-1958414417),r=c(r,s,i,l,t[f+10],17,-42063),l=c(l,r,s,i,t[f+11],22,-1990404162),i=c(i,l,r,s,t[f+12],7,1804603682),s=c(s,i,l,r,t[f+13],12,-40341101),r=c(r,s,i,l,t[f+14],17,-1502002290),l=c(l,r,s,i,t[f+15],22,1236535329),i=u(i,l,r,s,t[f+1],5,-165796510),s=u(s,i,l,r,t[f+6],9,-1069501632),r=u(r,s,i,l,t[f+11],14,643717713),l=u(l,r,s,i,t[f+0],20,-373897302),i=u(i,l,r,s,t[f+5],5,-701558691),s=u(s,i,l,r,t[f+10],9,38016083),r=u(r,s,i,l,t[f+15],14,-660478335),l=u(l,r,s,i,t[f+4],20,-405537848),i=u(i,l,r,s,t[f+9],5,568446438),s=u(s,i,l,r,t[f+14],9,-1019803690),r=u(r,s,i,l,t[f+3],14,-187363961),l=u(l,r,s,i,t[f+8],20,1163531501),i=u(i,l,r,s,t[f+13],5,-1444681467),s=u(s,i,l,r,t[f+2],9,-51403784),r=u(r,s,i,l,t[f+7],14,1735328473),l=u(l,r,s,i,t[f+12],20,-1926607734),i=h(i,l,r,s,t[f+5],4,-378558),s=h(s,i,l,r,t[f+8],11,-2022574463),r=h(r,s,i,l,t[f+11],16,1839030562),l=h(l,r,s,i,t[f+14],23,-35309556),i=h(i,l,r,s,t[f+1],4,-1530992060),s=h(s,i,l,r,t[f+4],11,1272893353),r=h(r,s,i,l,t[f+7],16,-155497632),l=h(l,r,s,i,t[f+10],23,-1094730640),i=h(i,l,r,s,t[f+13],4,681279174),s=h(s,i,l,r,t[f+0],11,-358537222),r=h(r,s,i,l,t[f+3],16,-722521979),l=h(l,r,s,i,t[f+6],23,76029189),i=h(i,l,r,s,t[f+9],4,-640364487),s=h(s,i,l,r,t[f+12],11,-421815835),r=h(r,s,i,l,t[f+15],16,530742520),l=h(l,r,s,i,t[f+2],23,-995338651),i=d(i,l,r,s,t[f+0],6,-198630844),s=d(s,i,l,r,t[f+7],10,1126891415),r=d(r,s,i,l,t[f+14],15,-1416354905),l=d(l,r,s,i,t[f+5],21,-57434055),i=d(i,l,r,s,t[f+12],6,1700485571),s=d(s,i,l,r,t[f+3],10,-1894986606),r=d(r,s,i,l,t[f+10],15,-1051523),l=d(l,r,s,i,t[f+1],21,-2054922799),i=d(i,l,r,s,t[f+8],6,1873313359),s=d(s,i,l,r,t[f+15],10,-30611744),r=d(r,s,i,l,t[f+6],15,-1560198380),l=d(l,r,s,i,t[f+13],21,1309151649),i=d(i,l,r,s,t[f+4],6,-145523070),s=d(s,i,l,r,t[f+11],10,-1120210379),r=d(r,s,i,l,t[f+2],15,718787259),l=d(l,r,s,i,t[f+9],21,-343485551),i=i+w>>>0,l=l+I>>>0,r=r+L>>>0,s=s+E>>>0}return Oa([i,l,r,s])};const Hu=function(e,n,t,a,i,l,r){var s=e+(n&t|~n&a)+(i>>>0)+r;return(s<<l|s>>>32-l)+n},Vu=function(e,n,t,a,i,l,r){var s=e+(n&a|t&~a)+(i>>>0)+r;return(s<<l|s>>>32-l)+n},Gu=function(e,n,t,a,i,l,r){var s=e+(n^t^a)+(i>>>0)+r;return(s<<l|s>>>32-l)+n},Ku=function(e,n,t,a,i,l,r){var s=e+(t^(n|~a))+(i>>>0)+r;return(s<<l|s>>>32-l)+n},Wu=function(e){for(var n=[],t=0;t<e.length;t++)n.push(255&e.charCodeAt(t));return n},Yu=function(e){for(var n=[],t=0,a=0;t<e.length;t++,a+=8)n[a>>>5]|=e[t]<<24-a%32;return n},Qu=function(e){for(var n=[],t=0;t<32*e.length;t+=8)n.push(e[t>>>5]>>>24-t%32&255);return n},Oa=function(e){if(e.constructor==Number)return 16711935&Oo(e,8)|4278255360&Oo(e,24);for(var n=0;n<e.length;n++)e[n]=Oa(e[n]);return e},Oo=function(e,n){return e<<n|e>>>32-n},Ju=function(e){for(var n=[],t=0;t<e.length;t++)n.push((e[t]>>>4).toString(16)),n.push((15&e[t]).toString(16));return n.join("")},qu=(e,n)=>{const a=`,live_id=1,aid=6383,version_code=180800,webcast_sdk_version=1.0.14-beta.0,room_id=${e},sub_room_id=,sub_channel_id=,did_rule=3,user_unique_id=${n},device_platform=web,device_type=,ac=,identity=audience`.substring(1),i=Pu(a),l=Qu(i),r=Ju(l);return window.byted_acrawler.frontierSign({"X-MS-STUB":r})["X-Bogus"]},Xu=(e,n)=>{const t=D();let a,i=new ResizeObserver(l=>{clearTimeout(a),a=setTimeout(()=>{t.value.resize()},500)});return wt(()=>{i.observe(e.value),n.canvas=e.value,t.value=new ef(n)}),In(()=>{i.unobserve(e.value),clearTimeout(a)}),t};class ef{constructor(n){he(this,"canvas");he(this,"colors");he(this,"ctx");he(this,"isdraw");he(this,"lines");he(this,"textList");he(this,"fontSize");he(this,"font");he(this,"rows");he(this,"gap");he(this,"speed");he(this,"opacity");he(this,"opacityStr");this.isdraw=!1,this.textList=[],this.canvas=n.canvas,this.ctx=this.canvas.getContext("2d"),this.speed=n.speed||2,this.setFont(n.fontSize||16),this.setGap(n.gap||8),this.setRows(n.rows||4),this.setOpacity(n.opacity||100),this.setColors(n.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(n){this.opacity=n;const t=Math.floor(2.55*n).toString(16);this.opacityStr=t.length==1?"0"+t:t}setRows(n){this.rows=n}setSpeed(n){this.speed=n}setFont(n){this.ctx.textBaseline="top",this.fontSize=n,this.font=`${n}px sans-serif`}setGap(n){this.gap=n}setColors(n){this.colors=n}clean(){this.textList=[],this.isdraw=!1}destory(){this.lines=[],this.clean()}add(n){const t=this.getLine();if(t==-1)return;const a=Math.ceil(this.ctx.measureText(n).width),i=this.canvas.width+a;this.lines[t].width=i,this.textList.push({value:n,width:a,line:t,left:this.canvas.width,color:this.colors[Math.floor(Math.random()*this.colors.length)]}),!this.isdraw&&(this.isdraw=!0,this.draw())}getLine(){let n=-1,t=this.lines.length;for(;++n<t;)if(this.lines[n].width==this.canvas.width)return n;return-1}initRows(){this.lines=[];let n=-1;const t=this.gap+this.fontSize;for(;++n<this.rows;)this.lines.push({top:this.gap+t*n,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 n=-1,t=this.textList.length;const a=[];for(;++n<t;){const i=this.textList[n],l=i.left+i.width;if(l<=0)continue;this.ctx.fillStyle=i.color+this.opacityStr;const r=this.lines[i.line];r&&(this.ctx.fillText(i.value,i.left,this.lines[i.line].top),i.left-=this.speed,a.push(i),r.width=Math.max(l,this.canvas.width))}this.textList=a,a.length==0?this.isdraw=!1:requestAnimationFrame(this.draw.bind(this))}}const tf={"w-full":"","h-full":"",flex:"","flex-col":"","lg:flex-row":"","box-border":"","md:pb-2":""},nf={"lg:grow-5":"",flex:"","flex-col":""},of={flex:"","p-2":"","pt-1":"","gap-2":"","text-lg":"","md:pr-3":""},af={"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":""},lf={"aspect-ratio-video":""},sf={"w-full":"","h-full":"","pos-absolute":"","top-0":"","z-1":"",flex:"","justify-center":"","items-center":"","text-6":""},rf=["src"],cf={key:0},uf={class:"flex items-center gap-4 p-1"},ff={class:"flex items-center gap-4 p-1"},df={key:1,"h-0":"","w-0":""},hf={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":""},_f={flex:"","items-center":"","line-height-none":"","gap-4":"",b:"","b-y-solid":"","py-3":"","b-gray-7":"","px-4":""},pf=["src"],vf={"grow-1":"","w-20":""},gf={"h-4":"",truncate:""},mf={"h-4":"",flex:"","text-3":"","items-center":"","gap-1":""},wf=["src"],xf={"pos-absolute":"","top-0":"","right-4":"","text-4":"",flex:"","flex-col":"","gap-3":""},yf=["src"],bf=["href"],kf=["data-id","data-site","href"],Sf={flex:"","items-center":"","gap-2":""},Af={"w-5":"","h-5":"","rounded-5":"",alt:""},Ef=["onClick"],If={flex:"","flex-col":"",b:"","b-solid":"","b-gray-6":"","rounded-2":"","px-2":""},Tf={flex:"","justify-between":"","items-center":"","mx-2":"","py-2":""},Cf={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},zf={flex:"","justify-between":"","items-center":"","mx-2":"","py-2":""},Rf={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Mf={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Of={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Lf={flex:"","flex-col":"",b:"","b-solid":"","b-gray-6":"","rounded-2":"","px-2":""},Df={flex:"","justify-between":"","items-center":"","mx-2":"","py-2":""},Uf={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Bf={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},$f={flex:"","justify-between":"","items-center":"",b:"","b-t-gray-6":"","b-t-solid":"","mx-2":"","py-2":""},Ff={flex:"","flex-wrap":"",shadow:"",blur:"","bg-dark":"","p-2":"","box-border":"",b:"","b-solid":"","b-gray-7":"",style:{"box-shadow":"0 6px 15px 0 rgba(0, 0, 0, .5)"},rounded:""},Nf=["data-color"],Zf={"p-3":"","bg-sm":"",flex:"","justify-between":"","items-center":""},jf=le({__name:"play",setup(e){let n,t,a;const i=je({follow:!1,qn:0,line:0,notice:null,paused:!0,muted:!1,fullscreen:!1,webscreen:!1,showController:!0,pictureInPicture:!1}),l=pi(),r=D(),s=D(),f=D(),c=il(),u=J(()=>{var A,m;return c.value&&((m=(A=c.value)==null?void 0:A.stream)==null?void 0:m.length)>0?c.value.stream.map(F=>F.name):[]}),h=J(()=>u.value.length>0?c.value.stream[i.qn].lines.map(A=>A.name):[]),d=J(()=>h.value.length>0?c.value.stream[i.qn].lines[i.line].url:""),w=J(()=>W.map(A=>Object.values(A.follows)).flat().sort(A=>A.status?-1:0)),I=J(()=>{var A;return((A=c.value)==null?void 0:A.siteId)=="bilibili"?"hls":"flv"});let L;const E=J(()=>{var A;return((A=c.value)==null?void 0:A.siteId)=="huya"&&(["一起看","星秀","原创"].includes(c.value.category)||c.value.info.name.endsWith("-imgplus"))}),k=()=>{E.value&&(L=setInterval(()=>{const A=Fi(c.value.info);i.flv.switchURL(d.value+A,!0)},11e4))};we(d,()=>{var A,m;if(clearInterval(L),!!d.value){if(I.value=="flv"){const F=c.value.siteId=="huya"?d.value+Fi(c.value.info):d.value;if(i.flv)return(A=i.flv)==null||A.switchURL(F,!0),k();if(rn!=null&&rn.isSupported("video")){const N=new rn({media:s.value,seamlesslyReload:!0,isLive:!0,retryCount:0});return N.load(F),i.flv=N,k()}}if(i.hls)return(m=i.hls)==null?void 0:m.loadSource(d.value);if(cn!=null&&cn.isSupported()){const F=new cn;return F.attachMedia(s.value),F.loadSource(d.value),i.hls=F}return i.notice="播放失败",clearTimeout(t)}}),we(I,()=>{var A,m;if(I.value=="flv"){(A=i.hls)==null||A.destroy(),i.hls=void 0;return}(m=i.flv)==null||m.destroy(),i.flv=void 0});const M=()=>{f.value.scrollTop=0,me=0,f.value.innerHTML=""};let S,b=0,x=!0;const p=D(),_=Xu(p,{gap:C.canvasGap,rows:C.canvasRows,speed:C.canvasSpeed,opacity:C.canvasOpacity,colors:C.canvasColorOpen?C.colors:["#ffffff"]}),g=[];let $;function B(){$||($=setTimeout(()=>{let A=-1;const m=g.length>5?5:g.length;for(f.value.style.display="none";++A<m;)f.value.appendChild(g[A]);f.value.style.display="block",g.splice(0,5),x&&(f.value.scrollTop=f.value.scrollHeight),$=void 0},200))}const O=(A,m)=>{var qe;if(b++,C.blockOpen&&ji.value.length&&ji.value.some(st=>st.test(m))||(b%(C.sideClean||100)==0&&(f.value.innerHTML="",me=0),C.canvasOpen&&((qe=_.value)==null||qe.add(m)),!ft.value||!C.sideOpen))return;const F=document.createElement("div"),{sideColorOpen:N,sideFontsize:V,sideGap:te,colors:Ee}=C;F.style.margin=`${te}px 0`,F.style.fontSize=`${V}px`,N&&(F.style.color=Ee[Math.floor(Math.random()*Ee.length)]);const Ce=document.createElement("span");Ce.style.opacity="0.5",Ce.appendChild(document.createTextNode(A+":"));const lt=document.createElement("span");lt.appendChild(document.createTextNode(m)),F.appendChild(Ce),F.appendChild(lt),g.push(F),B()};let me=0;const Fe=()=>{if(f.value.scrollTop>=me)return me=f.value.scrollTop;me=f.value.scrollTop,x=!1,f.value.removeEventListener("scroll",Fe)},at=()=>{x=!0,f.value.scrollTop=f.value.scrollHeight,f.value.addEventListener("scroll",Fe,{passive:!1})};let se;const Ii=async()=>{var m,F;if(!((m=c.value)!=null&&m.ws)||S||!C.canvasOpen&&!C.sideOpen)return;let A=!0;if(c.value.siteId=="huya"){const N=(F=c.value)==null?void 0:F.ws;if(!N)return;S=new WebSocket(N),S.onopen=()=>{clearInterval(se),O("系统","开始连接弹幕服务器"),f.value.addEventListener("scroll",Fe),S==null||S.send(JSON.stringify({command:"subscribeNotice",data:["getMessageNotice"],reqId:Date.now().toString()})),se=setInterval(()=>{S.send("ping")},45e3)},S.onmessage=V=>{if(A)return O("系统","弹幕服务器连接成功"),A=!1;const{sendNick:te,content:Ee}=JSON.parse(V.data).data;O(te,Ee)},S.onerror=()=>{clearInterval(se),O("系统","弹幕服务器连接失败")}}else if(c.value.siteId=="douyu")S=new WebSocket("wss://danmuproxy.douyu.com:8506"),S.onopen=()=>{var N,V;clearInterval(se),O("系统","开始连接弹幕服务器"),f.value.addEventListener("scroll",Fe),S.send(tn(`type@=loginreq/roomid@=${(N=c.value)==null?void 0:N.roomId}`)),S.send(tn(`type@=joingroup/rid@=${(V=c.value)==null?void 0:V.roomId}/gid@=-9999`)),se=setInterval(()=>{S.send(tn("type@=mrkl/"))},45e3)},S.onmessage=async({data:N})=>{A&&(O("系统","弹幕服务器连接成功"),A=!1),(await N.text()).split(/type@=chatmsg\//).forEach(Ee=>{const Ce=Ee.match(/nn@=(.*)\/txt@=(.*)\/cid/);Ce!=null&&O(Ce[1],Ce[2])})},S.onerror=()=>{clearInterval(se),O("系统","弹幕服务器连接失败")};else if(c.value.siteId=="douyin"){const N=c.value.ws.split(","),V=N[0],te=N[1],Ee=qu(V,te);let Ce=`wss://webcast5-ws-web-lf.douyin.com/webcast/im/push/v2/?room_id=${V}&compress=gzip&version_code=180800&webcast_sdk_version=1.0.14-beta.0&live_id=1&did_rule=3&user_unique_id=${te}&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(Ce),S.binaryType="arraybuffer",S.onopen=()=>{clearInterval(se),O("系统","开始连接弹幕服务器"),f.value.addEventListener("scroll",Fe),se=setInterval(()=>{(S==null?void 0:S.readyState)==1&&S.send(Ru({payloadType:"bh"}))},1e4)},S.onmessage=lt=>{A&&(O("系统","弹幕服务器连接成功"),A=!1);const qe=Ou(new Uint8Array(lt.data)),st=Su(qe.payload),Ne=Au(new Uint8Array(st)).messagesList;if(!Ne||Ne.length==0)return;const an=Ne.length;let rt=-1;for(;++rt<an;){if(Ne[rt].method!="WebcastChatMessage")continue;const R=Tu(Ne[rt].payload);O(R.user.nickName,R.content)}},S.onerror=function(){clearInterval(se),O("系统","弹幕服务器连接失败")}}},Ti=new TextEncoder;function tn(A){let m=Ti.encode(A);const F=9+m.byteLength,N=[F,0,0,.1,F,0,0,0,177,2,0,0];m=Ti.encode(A+"\0");const V=new Uint8Array(12+m.byteLength);return V.set(N),V.set(m,12),V.buffer}const Ln=()=>{clearInterval(se),S&&(S.onmessage=null,Mi=="douyu"?S.send(tn("type@=logout")):S.close(),S=null,b=0,f.value&&nn==l.fullPath&&O("系统","弹幕服务器断开连接"))};we(c,()=>Ii()),we([()=>C.sideOpen,()=>C.canvasOpen],()=>{!C.sideOpen&&!C.canvasOpen&&Ln(),S||Ii()});const Dn=()=>{const{site:A,id:m}=l.meta,F=l.meta.site.follows[m];F&&(c.value=F,i.follow=!0),clearInterval(L),clearInterval(se),clearTimeout(t),i.notice="加载中...",Fn(()=>{O("系统","开始获取直播间信息")}),De(A.id,"getRoomDetail",{id:m}).then(N=>{if(c.value=N,i.follow&&Mt(N),Fn(()=>O("系统","直播间信息获取成功")),!N.status)return i.notice="未开播!";document.title=c.value.title},N=>{i.notice=N,Fn(()=>O("系统","直播间信息获取失败"))}).finally(()=>clearTimeout(t))},Ua=()=>{if(!c.value)return;const{id:A}=l.meta.site;i.follow=i.follow?ii(A,c.value.roomId):Mt(c.value)},Un=()=>{!c.value||!c.value.status||(clearTimeout(n),n=setTimeout(()=>{i.paused?s.value.play():s.value.pause()},200))},Ci=()=>{clearTimeout(n),i.fullscreen=!i.fullscreen,document.fullscreenElement?document.exitFullscreen():r.value.requestFullscreen()},Je=()=>{clearTimeout(a),i.showController=!0,a=setTimeout(()=>{var A,m;(A=s.value)!=null&&A.paused||!((m=s.value)!=null&&m.played.length)||(i.showController=!1)},3e3)},Ba=()=>{clearTimeout(n),i.webscreen=!i.webscreen,i.fullscreen&&(i.fullscreen=!1,document.exitFullscreen())},$a=()=>{i.paused=!1,Je()},Fa=()=>{i.paused=!0,Je()},zi=A=>{if(d.value)switch(A.code){case"ArrowDown":return ln(!1);case"ArrowUp":return ln(!0);case"Space":return Un()}},Na=()=>{var A;clearTimeout(n),clearTimeout(a),clearTimeout(t),clearTimeout($),clearInterval(L),Ln(),document.title="Lemon live",document.removeEventListener("keydown",zi),I.value&&!i.pictureInPicture&&((A=i[I.value])==null||A.destroy())};Dn();const Ri=Cn();let nn=l.fullPath;wt(()=>{r.value.style.filter=de.value==100?"":`brightness(${de.value/100})`,s.value.volume=xe.value/100,i.muted=s.value.muted,s.value.addEventListener("canplay",()=>{i.notice=null}),mn||(r.value.addEventListener("mousemove",Je),document.addEventListener("keydown",zi)),document.pictureInPictureElement&&document.exitPictureInPicture(),s.value.addEventListener("leavepictureinpicture",()=>{var A;if(!/play/.test(l.path))return Ri.push(nn);if(l.fullPath==nn)return i.pictureInPicture=!1;(A=i[I.value])==null||A.destroy()})});let Mi=l.meta.site.id;Al(A=>{var V;const{siteid:m,id:F}=A.params,N=ht.findIndex(te=>te==m);return N==-1?{name:"404"}:(A.meta.site=W[N],A.meta.id=F,I.value&&((V=i[I.value])==null||V.destroy(),i[I.value]=void 0),i.qn=0,i.line=0,i.follow=!1,c.value=void 0,!0)}),we(()=>l.params,()=>{var A;clearTimeout($),Ln(),M(),(A=_.value)==null||A.destory(),Mi=l.meta.site.id,nn=l.fullPath,Dn()}),In(Na);const Za=()=>Promise.all(yn(W,ni)),ja=async A=>{A==1&&await Za()},Pa=()=>i.showController?Un():Je(),Ha=()=>{i.pictureInPicture=!i.pictureInPicture,document.pictureInPictureElement?document.exitPictureInPicture():s.value.requestPictureInPicture()},Va=A=>{const m=A.target.dataset.color;if(!m)return;const F=C.colors.findIndex(N=>N==m);if(F==-1)return C.colors.push(m);C.colors.length!=1&&C.colors.splice(F,1)};we(()=>C.colors,()=>{var A;return(A=_.value)==null?void 0:A.setColors(C.colors)}),we(()=>C.canvasSpeed,()=>{var A;return(A=_.value)==null?void 0:A.setSpeed(C.canvasSpeed)}),we(()=>C.canvasOpacity,()=>{var A;return(A=_.value)==null?void 0:A.setOpacity(C.canvasOpacity)}),we(()=>C.canvasColorOpen,()=>{var A;return(A=_.value)==null?void 0:A.setColors(C.canvasColorOpen?C.colors:["#ffffff"])}),Gt(()=>{var A,m,F,N;(A=_.value)==null||A.setGap(C.canvasGap),(m=_.value)==null||m.setFont(C.canvasFontsize),(F=_.value)==null||F.setRows(C.canvasRows),(N=_.value)==null||N.resize()}),we(xe,()=>{Je(),clearTimeout(t),i.notice=`当前音量 ${xe.value}%`,s.value.volume=xe.value/100,pt("volume",xe.value),t=setTimeout(()=>i.notice=null,2e3)}),we(de,()=>{Je(),clearTimeout(t),i.notice=`当前亮度 ${de.value}%`,r.value.style.filter=de.value==100?"":`brightness(${de.value/100})`,pt("brightness",de.value),t=setTimeout(()=>i.notice=null,2e3)});let Bn;const on=D(),Ga=A=>{clearTimeout(Bn),Bn=setTimeout(()=>{const m=Et("id",A.target,on.value);if(!m)return;const F=Et("site",A.target,on.value);Ri.push(`/${F}/play/${m}`)},300)},Ka=A=>{var V;clearTimeout(Bn);const m=Et("id",A.target,on.value);if(!m)return;const N=`/${Et("site",A.target,on.value)}/play/${m}`;(V=window.open(N,"_blank"))==null||V.location},Et=(A,m,F)=>{if(m==F)return null;const N=m.dataset[A];return N||Et(A,m.parentElement,F)},Wa=()=>de.value=100;we(()=>i.muted,()=>{Je(),clearTimeout(t),i.notice=i.muted?"已静音":"已开启声音",t=setTimeout(()=>i.notice=null,2e3)});const Ya=()=>{if(s.value.muted){s.value.muted=!1,i.muted=!1;return}s.value.muted=!0,i.muted=!0};function Qa(A,m,F){F.stopPropagation(),F.preventDefault(),ii(A,m),A==c.value.siteId&&m==c.value.roomId&&(i.follow=!1)}return(A,m)=>{var qe,st,$n,Ne,an,rt;const F=Qs,N=Vs,V=Yt,te=js,Ee=Ns,Ce=Wt,lt=En("lazy");return T(),U("div",tf,[v("div",nf,[v("div",of,[v("div",{"hover:text-amber":"",onClick:m[0]||(m[0]=(...R)=>A.$router.back&&A.$router.back(...R)),class:"i-ri-arrow-left-line"}),v("h1",af,Z((qe=y(c))==null?void 0:qe.title),1),v("div",{onClick:m[1]||(m[1]=R=>ft.value=!y(ft)),hidden:"","lg:block":"",style:dt(y(ft)?"transform:rotate(180deg)":"margin-right:1.5rem"),class:"i-ri-arrow-right-s-fill"},null,4)]),v("div",{ref_key:"player",ref:r,"md:rounded-6px":"","text-4":"","text-white":"",onContextmenu:m[19]||(m[19]=q(()=>{},["prevent"])),"bg-black":"","cursor-default":"",class:Y({"cursor-none":!y(i).showController,"text-5":y(i).fullscreen,"text-5 !pos-fixed left-0 right-0 top-0 bottom-0 z-10 ":y(i).webscreen}),"pos-relative":"","w-full":"","overflow-hidden":"","select-none":"","h-full":"",onClick:Pa,onDblclick:Ci},[v("div",lf,[v("video",{playsinline:"","webkit-playsinline":"","x5-video-player-type":"h5",autoplay:"",ref_key:"video",ref:s,"w-full":"","h-full":"","pos-absolute":"",onPlay:$a,onPause:Fa},null,544)]),Q(v("div",sf,[v("span",null,Z(y(i).notice),1)],512),[[ke,y(i).notice]]),v("canvas",{ref_key:"canvas",ref:p,"pos-absolute":"","top-0":"",width:"0",height:"0","w-full":"","h-full":"","z-1":""},null,512),Q(v("div",{"pos-absolute":"","bottom-0":"","left-0":"","right-0":"","px-4":"","py-2":"","gap-3":"","z-20":"",flex:"","items-center":"",onClick:m[5]||(m[5]=q(()=>{},["stop"])),onDblclick:m[6]||(m[6]=q(()=>{},["stop"])),class:Y({"py-3":y(i).fullscreen||y(i).webscreen}),"bg-black":"","bg-op-30":""},[v("div",{onClick:Un,"hover:text-amber":"",class:Y(y(i).paused?"i-ri-play-large-fill":"i-ri-pause-large-fill")},null,2),v("div",{"hover:text-amber":"",onClick:Ua,class:Y(y(i).follow?"i-ri-heart-fill":"i-ri-heart-line")},null,2),v("div",{"hover:text-amber":"",onClick:Dn,class:"i-ri-refresh-line"}),v("img",{"w-1.5em":"","cursor-pointer":"",onClick:m[2]||(m[2]=()=>y(C).canvasOpen=!y(C).canvasOpen),src:y(C).canvasOpen?y(Pi):y(Hi)},null,8,rf),m[33]||(m[33]=v("div",{grow:""},null,-1)),y(u).length?(T(),U("div",cf,[H(F,{active:y(i).qn,"onUpdate:active":m[3]||(m[3]=R=>y(i).qn=R),list:y(u)},null,8,["active","list"]),H(F,{active:y(i).line,"onUpdate:active":m[4]||(m[4]=R=>y(i).line=R),list:y(h)},null,8,["active","list"]),y(mn)?Le("",!0):(T(),U("div",{key:0,"ml-2":"","hover:text-amber":"",onClick:Ha,class:Y(y(i).pictureInPicture?"i-ri-picture-in-picture-exit-line":"i-ri-picture-in-picture-2-line")},null,2))])):Le("",!0),v("div",{"hover:text-amber":"",onClick:Ba,class:"i-mdi-fit-to-screen"}),v("div",{"hover:text-amber":"",onClick:Ci,class:Y(y(i).fullscreen?"i-ri-fullscreen-exit-fill":"i-ri-fullscreen-fill")},null,2)],34),[[ke,y(i).showController]]),y(mn)?Q((T(),U("div",{key:0,class:Y({"py-3":y(i).fullscreen||y(i).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:m[11]||(m[11]=q(()=>{},["stop"])),onDblclick:m[12]||(m[12]=q(()=>{},["stop"]))},[v("div",uf,[v("div",{onClick:m[7]||(m[7]=R=>y(Ni)(!1)),class:"i-ri-sun-line"}),v("div",null,Z(y(de)),1),v("div",{onClick:m[8]||(m[8]=R=>y(Ni)(!0)),class:"i-ri-sun-fill"})]),Q(v("div",{"flex-1":"","w-10":"",truncate:"","text-center":""},Z((st=y(c))==null?void 0:st.title),513),[[ke,y(i).fullscreen]]),v("div",ff,[v("div",{onClick:m[9]||(m[9]=R=>y(ln)(!1)),class:"i-ri-volume-down-fill"}),v("div",null,Z(y(xe)),1),v("div",{onClick:m[10]||(m[10]=R=>y(ln)(!0)),class:"i-ri-volume-up-fill"})])],34)),[[ke,y(i).showController]]):Q((T(),U("div",df,[v("div",{onClick:m[14]||(m[14]=q(()=>{},["stop"])),onDblclick:m[15]||(m[15]=q(()=>{},["stop"])),"pos-absolute":"",class:"top-50% left-4 flex items-center flex-col",style:{transform:"translateY(-50%)"},"z-20":""},[v("div",null,Z(y(de)),1),H(N,{value:y(de),"onUpdate:value":m[13]||(m[13]=R=>We(de)?de.value=R:null),max:200,min:50},null,8,["value"]),v("div",{onClick:q(Wa,["stop"]),class:"i-ri-sun-line"})],32),v("div",{onClick:m[17]||(m[17]=q(()=>{},["stop"])),onDblclick:m[18]||(m[18]=q(()=>{},["stop"])),"pos-absolute":"",class:"top-50% right-4 flex items-center flex-col",style:{transform:"translateY(-50%)"},"z-20":""},[Rt(Z(y(xe))+" ",1),H(N,{value:y(xe),"onUpdate:value":m[16]||(m[16]=R=>We(xe)?xe.value=R:null),max:100,min:0},null,8,["value"]),v("div",{onClick:q(Ya,["stop"]),class:Y(y(i).muted?"i-ri-volume-mute-line":"i-ri-volume-down-line")},null,2)],32)],512)),[[ke,y(i).showController]])],34)]),Q(v("div",hf,[v("div",_f,[v("img",{src:($n=y(c))==null?void 0:$n.avatar,"w-8":"","h-8":"",alt:"","rounded-4":""},null,8,pf),v("div",vf,[v("div",gf,Z((Ne=y(c))==null?void 0:Ne.nickname),1),v("div",mf,[v("img",{"w-4":"","h-4":"",src:A.$route.meta.site.icon},null,8,wf),Rt(" "+Z(A.$route.meta.site.name)+" "+Z((an=y(c))==null?void 0:an.category),1)])]),v("div",null,[m[34]||(m[34]=v("div",{"mx-1":"",class:"i-mdi-fire"},null,-1)),v("span",null,Z((rt=y(c))==null?void 0:rt.online),1)])]),H(Ce,{grow:!0,onTabClick:ja,class:"!h-[calc(100%-3.75rem)]"},{default:K(()=>[H(V,{title:"聊天","pos-relative":""},{default:K(()=>{var R;return[v("div",xf,[v("img",{"w-1.5em":"","cursor-pointer":"",onClick:m[20]||(m[20]=()=>y(C).sideOpen=!y(C).sideOpen),src:y(C).sideOpen?y(Pi):y(Hi)},null,8,yf),v("div",{"text-green-5":"",onClick:M,class:"i-ri-delete-bin-3-line"}),v("a",{"text-green-5":"",href:(R=y(c))==null?void 0:R.url,target:"_blank"},m[35]||(m[35]=[v("div",{class:"i-ri-link"},null,-1)]),8,bf),v("div",{onClick:at,"text-green-5":"",class:"i-ri-arrow-down-circle-line"})]),v("div",{ref_key:"dm",ref:f,"h-full":"","pl-2":"","box-border":"",class:"scrolly"},null,512)]}),_:1}),H(V,{title:"关注","box-border":"","px-4":""},{default:K(()=>[v("div",{onClick:q(Ga,["prevent"]),onDblclick:q(Ka,["prevent"])},[(T(!0),U(oe,null,ge(y(w),R=>{var Oi,Li;return T(),U("a",{"data-id":R.roomId,"data-site":R.siteId,class:Y({"text-amber":((Oi=y(c))==null?void 0:Oi.siteId)==R.siteId&&((Li=y(c))==null?void 0:Li.roomId)==R.roomId}),key:`${R.siteId}/${R.roomId}`,href:`/${R.siteId}/play/${R.roomId}`,flex:"","items-center":"","justify-between":"","gap-2":"","py-2":""},[v("div",Sf,[Q(v("img",Af,null,512),[[lt,R.avatar]]),v("div",null,Z(y(xl)[R.siteId]),1),v("div",null,Z(R.nickname),1),v("div",{"inline-block":"","w-3":"","h-3":"","rounded-3":"",class:Y([R.status?"bg-green":"bg-red"])},null,2),v("div",null,Z(R.status?"直播中":"未开播"),1)]),v("div",{"pos-relative":"","w-6":"","h-6":"","hover:text-amber":"",class:"i-mdi-heart-off-outline",onClick:Ja=>Qa(R.siteId,R.roomId,Ja)},null,8,Ef)],10,kf)}),128))],32)]),_:1}),H(V,{title:"设置","px-2":""},{default:K(()=>[m[47]||(m[47]=v("div",{"p-3":"","bg-sm":""},"弹幕",-1)),v("div",If,[v("div",Tf,[m[36]||(m[36]=v("div",null,"文字大小",-1)),H(te,{value:y(C).canvasFontsize,"onUpdate:value":m[21]||(m[21]=R=>y(C).canvasFontsize=R),max:80,min:8,step:1},null,8,["value"])]),v("div",Cf,[m[37]||(m[37]=v("div",null,"上下间隔",-1)),H(te,{value:y(C).canvasGap,"onUpdate:value":m[22]||(m[22]=R=>y(C).canvasGap=R),max:80,min:1,step:1},null,8,["value"])]),v("div",zf,[m[38]||(m[38]=v("div",null,"最大行数",-1)),H(te,{value:y(C).canvasRows,"onUpdate:value":m[23]||(m[23]=R=>y(C).canvasRows=R),max:50,min:1,step:1},null,8,["value"])]),v("div",Rf,[m[39]||(m[39]=v("div",null,"弹幕速度",-1)),H(te,{value:y(C).canvasSpeed,"onUpdate:value":m[24]||(m[24]=R=>y(C).canvasSpeed=R),max:32,min:.5,step:.5},null,8,["value"])]),v("div",Mf,[m[40]||(m[40]=v("div",null,"弹幕透明",-1)),H(te,{value:y(C).canvasOpacity,"onUpdate:value":m[25]||(m[25]=R=>y(C).canvasOpacity=R),max:100,min:10,step:10},null,8,["value"])]),v("div",Of,[m[41]||(m[41]=v("div",null,"彩色弹幕",-1)),H(Ee,{value:y(C).canvasColorOpen,"onUpdate:value":m[26]||(m[26]=R=>y(C).canvasColorOpen=R)},null,8,["value"])])]),m[48]||(m[48]=v("div",{"p-3":"","bg-sm":""},"聊天",-1)),v("div",Lf,[v("div",Df,[m[42]||(m[42]=v("div",null,"文字大小",-1)),H(te,{value:y(C).sideFontsize,"onUpdate:value":m[27]||(m[27]=R=>y(C).sideFontsize=R),max:80,min:8,step:1},null,8,["value"])]),v("div",Uf,[m[43]||(m[43]=v("div",null,"上下间隔",-1)),H(te,{value:y(C).sideGap,"onUpdate:value":m[28]||(m[28]=R=>y(C).sideGap=R),max:80,min:0,step:1},null,8,["value"])]),v("div",Bf,[m[44]||(m[44]=v("div",null,"自动清屏",-1)),H(te,{value:y(C).sideClean,"onUpdate:value":m[29]||(m[29]=R=>y(C).sideClean=R),max:500,min:10,step:10},null,8,["value"])]),v("div",$f,[m[45]||(m[45]=v("div",null,"彩色消息",-1)),H(Ee,{value:y(C).sideColorOpen,"onUpdate:value":m[30]||(m[30]=R=>y(C).sideColorOpen=R)},null,8,["value"])])]),m[49]||(m[49]=v("div",{"p-3":"","bg-sm":""},"颜色",-1)),v("div",Ff,[(T(!0),U(oe,null,ge(y(bl),R=>(T(),U("div",{onClick:Va},[v("div",{class:"w-4 h-4 rounded-2 m-2 shadow","box-border":"","data-color":R,"cursor-pointer":"",style:dt(`background:${R};${y(C).colors.includes(R)?"box-shadow:0 0 0px 2px white":""}`)},null,12,Nf)]))),256))]),v("div",Zf,[m[46]||(m[46]=Rt("屏蔽 ")),H(Ee,{value:y(C).blockOpen,"onUpdate:value":m[31]||(m[31]=R=>y(C).blockOpen=R)},null,8,["value"])]),Q(v("textarea",{"outline-none":"","w-full":"","onUpdate:modelValue":m[32]||(m[32]=R=>y(C).blockWords=R),"text-white":"",b:"","b-solid":"","b-gray-7":"","p-2":"","box-border":"",rows:"5","bg-dark":"",shadow:"","rounded-1":"",placeholder:"以空格分隔"},null,512),[[hi,y(C).blockWords,void 0,{trim:!0}]])]),_:1})]),_:1})],512),[[ke,y(ft)]])])}}}),La=(e,n)=>{const t=e.__vccOpts||e;for(const[a,i]of n)t[a]=i;return t},Pf={},Hf={"h-full":"","box-border":"","py-2":"",class:"scrolly"};function Vf(e,n){return T(),U("div",Hf,n[0]||(n[0]=[v("div",{"text-xl":"","p-4":""},"支持",-1),v("div",{"ml-4":""},[v("img",{"h-50":"","mr-5":"",src:"https://i0.hdslb.com/bfs/article/828b4686d0bcd7a427939b1f121f322898845873.png@1e_1c.webp"}),v("img",{"h-50":"",src:"https://i0.hdslb.com/bfs/article/d07b5e8cbae76f0fc38a8049c433d3d598845873.jpg@1e_1c.webp"})],-1)]))}const Gf=La(Pf,[["render",Vf]]),Kf={},Wf={"h-full":"",flex:"","justify-center":"","items-center":""};function Yf(e,n){return T(),U("div",Wf,n[0]||(n[0]=[v("div",{"text-center":"","text-8":"","line-height-8":""},[v("div",{"font-900":""},"404"),v("div",{"mt-4":""},"页面未找到")],-1)]))}const Qf=La(Kf,[["render",Yf]]);async function Tt(e){const{siteid:n,id:t}=e.params,a=W.findIndex(i=>i.id==n);return a==-1?{name:"404"}:(e.meta.site=W[a],e.meta.id=t,e.meta.index=a,ie.value=a,!0)}const Jf=kl({history:Sl(),routes:[{path:"/",redirect:()=>`/${ht[ie.value]}`},{path:"/follow",component:$s},{path:"/user",component:Gf},{path:"/category",redirect:()=>`/${ht[ie.value]}/category`},{path:"/search",redirect:()=>`/${ht[ie.value]}/search`},{path:"/:siteid",component:Fs,beforeEnter:Tt},{path:"/:siteid/category",component:us,beforeEnter:Tt},{path:"/:siteid/category/:id",component:Ql,beforeEnter:Tt},{path:"/:siteid/play/:id",component:jf,beforeEnter:Tt},{path:"/:siteid/search",component:vs,beforeEnter:Tt},{path:"/:pathMatch(.*)*",name:"404",component:Qf}]}),qf={install(e){e.directive("lazy",{mounted(n,t){n.src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9Im5vbmUiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41IiBkPSJtMi4yNSAxNS43NWw1LjE1OS01LjE1OWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGw1LjE1OSA1LjE1OW0tMS41LTEuNWwxLjQwOS0xLjQwOWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGwyLjkwOSAyLjkwOW0tMTggMy43NWgxNi41YTEuNSAxLjUgMCAwIDAgMS41LTEuNVY2YTEuNSAxLjUgMCAwIDAtMS41LTEuNUgzLjc1QTEuNSAxLjUgMCAwIDAgMi4yNSA2djEyYTEuNSAxLjUgMCAwIDAgMS41IDEuNW0xMC41LTExLjI1aC4wMDh2LjAwOGgtLjAwOHptLjM3NSAwYS4zNzUuMzc1IDAgMSAxLS43NSAwYS4zNzUuMzc1IDAgMCAxIC43NSAwIi8+PC9zdmc+";const a=new IntersectionObserver(i=>{Vo(i,l=>{if(l.isIntersecting){const r=new Image;r.src=t.value,r.onload=()=>n.src=t.value,a.unobserve(l.target)}})});a.observe(n)}})}},Da=el(Cl);Da.use(Jf).use(qf);Da.mount("#app");