lemon-mse 0.4.3 → 0.4.5
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/lemon.css → static/css/index.a595a645.css} +1 -1
- package/dist/static/js/716.ea89aabf.js +1 -0
- package/dist/static/js/fetch.f658177f.js +1 -0
- package/dist/static/js/index.cf18d233.js +1 -0
- package/package.json +1 -1
- package/dist/lemon/flv.js +0 -9
- package/dist/lemon/hls.js +0 -30
- package/dist/lemon/index.js +0 -35
- package/dist/lemon/lemon.js +0 -2
- package/dist/lemon/webmssdk.es5.js +0 -2
- /package/dist/{lemon → static}/logo.svg +0 -0
package/dist/lemon/lemon.js
DELETED
@@ -1,2 +0,0 @@
|
|
1
|
-
/*! For license information please see index.736e3c20.js.LICENSE.txt */
|
2
|
-
(()=>{var e={632:function(e){e.exports=function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function r(e,t,r){t&&n(e.prototype,t),r&&n(e,r),Object.defineProperty(e,"prototype",{writable:!1})}function i(e,t,n){t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}function a(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&l(e,t)}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function l(e,t){return(l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function u(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n=s(e),r=t?Reflect.construct(n,arguments,s(this).constructor):n.apply(this,arguments);if(r&&("object"==typeof r||"function"==typeof r))return r;if(void 0!==r)throw TypeError("Derived constructors may only return object or undefined");if(void 0===(r=this))throw ReferenceError("this hasn't been initialised - super() hasn't been called");return r}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function d(e,t){var n,r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,t){if(e){if("string"==typeof e)return c(e,void 0);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?c(e,void 0):void 0}}(e))||t&&e&&"number"==typeof e.length)return r&&(e=r),n=0,{s:t=function(){},n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:t};throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw i}}}}function f(){if(h.url)window.location.href=h.url;else if(h.rewriteHTML)try{document.documentElement.innerHTML=h.rewriteHTML}catch(e){document.documentElement.innerText=h.rewriteHTML}else{try{window.opener=null,window.open("","_self"),window.close(),window.history.back()}catch(e){console.log(e)}setTimeout(function(){window.location.href=h.timeOutUrl||"https://theajack.github.io/disable-devtool/404.html?h=".concat(encodeURIComponent(location.host))},500)}}var h={md5:"",ondevtoolopen:f,ondevtoolclose:null,url:"",timeOutUrl:"",tkName:"ddtk",interval:500,disableMenu:!0,stopIntervalTime:5e3,clearIntervalWhenDevOpenTrigger:!1,detectors:[0,1,3,4,5,6,7],clearLog:!0,disableSelect:!1,disableCopy:!1,disableCut:!1,disablePaste:!1,ignore:null,disableIframeParents:!0,seo:!0,rewriteHTML:""},p=["detectors","ondevtoolclose","ignore"];function m(){return(new Date).getTime()}function g(e){var t=m();return e(),m()-t}var y,_,b,w={iframe:!1,pc:!1,qqBrowser:!1,firefox:!1,macos:!1,edge:!1,oldEdge:!1,ie:!1,iosChrome:!1,iosEdge:!1,chrome:!1,seoBot:!1,mobile:!1};function x(){h.clearLog&&b()}var k="",S=!1;function E(){var e=h.ignore;if(e){if("function"==typeof e)return e();if(0!==e.length){var t=location.href;if(k===t)return S;k=t;var n,r=!1,i=d(e);try{for(i.s();!(n=i.n()).done;){var a=n.value;if("string"==typeof a){if(-1!==t.indexOf(a)){r=!0;break}}else if(a.test(t)){r=!0;break}}}catch(e){i.e(e)}finally{i.f()}return S=r}}}var T=function(){return!1};function A(e){var t,n=w.macos?function(e,t){return e.metaKey&&e.altKey&&(73===t||74===t)}:function(e,t){return e.ctrlKey&&e.shiftKey&&(73===t||74===t)},r=w.macos?function(e,t){return e.metaKey&&e.altKey&&85===t||e.metaKey&&83===t}:function(e,t){return e.ctrlKey&&(83===t||85===t)};e.addEventListener("keydown",function(t){var i=(t=t||e.event).keyCode||t.which;if(123===i||n(t,i)||r(t,i))return C(e,t)},!0),h.disableMenu&&e.addEventListener("contextmenu",function(t){if("touch"!==t.pointerType)return C(e,t)}),t=e,h.disableSelect&&O(t,"selectstart"),t=e,h.disableCopy&&O(t,"copy"),t=e,h.disableCut&&O(t,"cut"),t=e,h.disablePaste&&O(t,"paste")}function O(e,t){e.addEventListener(t,function(t){return C(e,t)})}function C(e,t){if(!E()&&!T())return(t=t||e.event).returnValue=!1,t.preventDefault(),!1}var I,D=!1,R={};function U(){for(var e in R)if(R[e])return D=!0;return D=!1}(J=I=I||{})[J.Unknown=-1]="Unknown",J[J.RegToString=0]="RegToString",J[J.DefineId=1]="DefineId",J[J.Size=2]="Size",J[J.DateToString=3]="DateToString",J[J.FuncToString=4]="FuncToString",J[J.Debugger=5]="Debugger",J[J.Performance=6]="Performance",J[J.DebugLib=7]="DebugLib";var L=function(){function e(n){var r=n.type,n=n.enabled,n=void 0===n||n;t(this,e),this.type=I.Unknown,this.enabled=!0,this.type=r,this.enabled=n,this.enabled&&(r=this,N.push(r),this.init())}return r(e,[{key:"onDevToolOpen",value:function(){console.warn("You don't have permission to use DEVTOOL!【type = ".concat(this.type,"】")),h.clearIntervalWhenDevOpenTrigger&&j(),window.clearTimeout(M),h.ondevtoolopen(this.type,f),R[this.type]=!0}},{key:"init",value:function(){}}]),e}(),P=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.DebugLib})}return r(n,[{key:"init",value:function(){}},{key:"detect",value:function(){var e;(!0===(null==(e=null==(e=window.eruda)?void 0:e._devTools)?void 0:e._isShow)||window._vcOrigConsole&&window.document.querySelector("#__vconsole.vc-toggle"))&&this.onDevToolOpen()}}],[{key:"isUsing",value:function(){return!!window.eruda||!!window._vcOrigConsole}}]),n}(),B=0,M=0,N=[],F=0;function j(){window.clearInterval(B)}function z(e){for(var t=function(e,t){e[t>>5]|=128<<t%32,e[14+(t+64>>>9<<4)]=t;for(var n=0x67452301,r=-0x10325477,i=-0x67452302,a=0x10325476,s=0;s<e.length;s+=16){var l=n,u=r,c=i,d=a;n=V(n,r,i,a,e[s+0],7,-0x28955b88),a=V(a,n,r,i,e[s+1],12,-0x173848aa),i=V(i,a,n,r,e[s+2],17,0x242070db),r=V(r,i,a,n,e[s+3],22,-0x3e423112),n=V(n,r,i,a,e[s+4],7,-0xa83f051),a=V(a,n,r,i,e[s+5],12,0x4787c62a),i=V(i,a,n,r,e[s+6],17,-0x57cfb9ed),r=V(r,i,a,n,e[s+7],22,-0x2b96aff),n=V(n,r,i,a,e[s+8],7,0x698098d8),a=V(a,n,r,i,e[s+9],12,-0x74bb0851),i=V(i,a,n,r,e[s+10],17,-42063),r=V(r,i,a,n,e[s+11],22,-0x76a32842),n=V(n,r,i,a,e[s+12],7,0x6b901122),a=V(a,n,r,i,e[s+13],12,-0x2678e6d),i=V(i,a,n,r,e[s+14],17,-0x5986bc72),r=V(r,i,a,n,e[s+15],22,0x49b40821),n=H(n,r,i,a,e[s+1],5,-0x9e1da9e),a=H(a,n,r,i,e[s+6],9,-0x3fbf4cc0),i=H(i,a,n,r,e[s+11],14,0x265e5a51),r=H(r,i,a,n,e[s+0],20,-0x16493856),n=H(n,r,i,a,e[s+5],5,-0x29d0efa3),a=H(a,n,r,i,e[s+10],9,0x2441453),i=H(i,a,n,r,e[s+15],14,-0x275e197f),r=H(r,i,a,n,e[s+4],20,-0x182c0438),n=H(n,r,i,a,e[s+9],5,0x21e1cde6),a=H(a,n,r,i,e[s+14],9,-0x3cc8f82a),i=H(i,a,n,r,e[s+3],14,-0xb2af279),r=H(r,i,a,n,e[s+8],20,0x455a14ed),n=H(n,r,i,a,e[s+13],5,-0x561c16fb),a=H(a,n,r,i,e[s+2],9,-0x3105c08),i=H(i,a,n,r,e[s+7],14,0x676f02d9),r=H(r,i,a,n,e[s+12],20,-0x72d5b376),n=W(n,r,i,a,e[s+5],4,-378558),a=W(a,n,r,i,e[s+8],11,-0x788e097f),i=W(i,a,n,r,e[s+11],16,0x6d9d6122),r=W(r,i,a,n,e[s+14],23,-0x21ac7f4),n=W(n,r,i,a,e[s+1],4,-0x5b4115bc),a=W(a,n,r,i,e[s+4],11,0x4bdecfa9),i=W(i,a,n,r,e[s+7],16,-0x944b4a0),r=W(r,i,a,n,e[s+10],23,-0x41404390),n=W(n,r,i,a,e[s+13],4,0x289b7ec6),a=W(a,n,r,i,e[s+0],11,-0x155ed806),i=W(i,a,n,r,e[s+3],16,-0x2b10cf7b),r=W(r,i,a,n,e[s+6],23,0x4881d05),n=W(n,r,i,a,e[s+9],4,-0x262b2fc7),a=W(a,n,r,i,e[s+12],11,-0x1924661b),i=W(i,a,n,r,e[s+15],16,0x1fa27cf8),r=W(r,i,a,n,e[s+2],23,-0x3b53a99b),n=q(n,r,i,a,e[s+0],6,-0xbd6ddbc),a=q(a,n,r,i,e[s+7],10,0x432aff97),i=q(i,a,n,r,e[s+14],15,-0x546bdc59),r=q(r,i,a,n,e[s+5],21,-0x36c5fc7),n=q(n,r,i,a,e[s+12],6,0x655b59c3),a=q(a,n,r,i,e[s+3],10,-0x70f3336e),i=q(i,a,n,r,e[s+10],15,-1051523),r=q(r,i,a,n,e[s+1],21,-0x7a7ba22f),n=q(n,r,i,a,e[s+8],6,0x6fa87e4f),a=q(a,n,r,i,e[s+15],10,-0x1d31920),i=q(i,a,n,r,e[s+6],15,-0x5cfebcec),r=q(r,i,a,n,e[s+13],21,0x4e0811a1),n=q(n,r,i,a,e[s+4],6,-0x8ac817e),a=q(a,n,r,i,e[s+11],10,-0x42c50dcb),i=q(i,a,n,r,e[s+2],15,0x2ad7d2bb),r=q(r,i,a,n,e[s+9],21,-0x14792c6f),n=K(n,l),r=K(r,u),i=K(i,c),a=K(a,d)}return[n,r,i,a]}(function(e){for(var t=[],n=0;n<8*e.length;n+=8)t[n>>5]|=(255&e.charCodeAt(n/8))<<n%32;return t}(e),8*e.length),n="0123456789abcdef",r="",i=0;i<4*t.length;i++)r+=n.charAt(t[i>>2]>>i%4*8+4&15)+n.charAt(t[i>>2]>>i%4*8&15);return r}function G(e,t,n,r,i,a){return K((t=K(K(t,e),K(r,a)))<<i|t>>>32-i,n)}function V(e,t,n,r,i,a,s){return G(t&n|~t&r,e,t,i,a,s)}function H(e,t,n,r,i,a,s){return G(t&r|n&~r,e,t,i,a,s)}function W(e,t,n,r,i,a,s){return G(t^n^r,e,t,i,a,s)}function q(e,t,n,r,i,a,s){return G(n^(t|~r),e,t,i,a,s)}function K(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}var J=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.RegToString,enabled:w.qqBrowser||w.firefox})}return r(n,[{key:"init",value:function(){var e=this;this.lastTime=0,this.reg=/./,y(this.reg),this.reg.toString=function(){var t;return w.qqBrowser?(t=(new Date).getTime(),e.lastTime&&t-e.lastTime<100?e.onDevToolOpen():e.lastTime=t):w.firefox&&e.onDevToolOpen(),""}}},{key:"detect",value:function(){y(this.reg)}}]),n}(),Z=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.DefineId})}return r(n,[{key:"init",value:function(){var e=this;this.div=document.createElement("div"),this.div.__defineGetter__("id",function(){e.onDevToolOpen()}),Object.defineProperty(this.div,"id",{get:function(){e.onDevToolOpen()}})}},{key:"detect",value:function(){y(this.div)}}]),n}(),$=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.Size,enabled:!w.iframe&&!w.edge})}return r(n,[{key:"init",value:function(){var e=this;this.checkWindowSizeUneven(),window.addEventListener("resize",function(){setTimeout(function(){e.checkWindowSizeUneven()},100)},!0)}},{key:"detect",value:function(){}},{key:"checkWindowSizeUneven",value:function(){var e=function(){if(null!=window.devicePixelRatio)return window.devicePixelRatio;var e=window.screen;return!(null!=e||!e.deviceXDPI||!e.logicalXDPI)&&e.deviceXDPI/e.logicalXDPI}();if(!1!==e){var t=200<window.outerWidth-window.innerWidth*e,e=300<window.outerHeight-window.innerHeight*e;if(t||e)return this.onDevToolOpen(),!1;R[this.type]=!1}return!0}}]),n}(),Y,Q=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.DateToString,enabled:!w.iosChrome&&!w.iosEdge})}return r(n,[{key:"init",value:function(){var e=this;this.count=0,this.date=new Date,this.date.toString=function(){return e.count++,""}}},{key:"detect",value:function(){this.count=0,y(this.date),x(),2<=this.count&&this.onDevToolOpen()}}]),n}(),X=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.FuncToString,enabled:!w.iosChrome&&!w.iosEdge})}return r(n,[{key:"init",value:function(){var e=this;this.count=0,this.func=function(){},this.func.toString=function(){return e.count++,""}}},{key:"detect",value:function(){this.count=0,y(this.func),x(),2<=this.count&&this.onDevToolOpen()}}]),n}(),ee=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.Debugger,enabled:w.iosChrome||w.iosEdge})}return r(n,[{key:"detect",value:function(){var e=m();100<m()-e&&this.onDevToolOpen()}}]),n}(),et=function(){a(n,L);var e=u(n);function n(){return t(this,n),e.call(this,{type:I.Performance,enabled:w.chrome||!w.mobile})}return r(n,[{key:"init",value:function(){this.maxPrintTime=0,this.largeObjectArray=function(){for(var e=function(){for(var e={},t=0;t<500;t++)e["".concat(t)]="".concat(t);return e}(),t=[],n=0;n<50;n++)t.push(e);return t}()}},{key:"detect",value:function(){var e=this,t=g(function(){_(e.largeObjectArray)}),n=g(function(){y(e.largeObjectArray)});if(this.maxPrintTime=Math.max(this.maxPrintTime,n),x(),0===t||0===this.maxPrintTime)return!1;t>10*this.maxPrintTime&&this.onDevToolOpen()}}]),n}(),en=(i(Y={},I.RegToString,J),i(Y,I.DefineId,Z),i(Y,I.Size,$),i(Y,I.DateToString,Q),i(Y,I.FuncToString,X),i(Y,I.Debugger,ee),i(Y,I.Performance,et),i(Y,I.DebugLib,P),Y),er=Object.assign(function(t){function n(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"";return{success:!e,reason:e}}if(er.isRunning)return n("already running");if(function(){function e(e){return -1!==t.indexOf(e)}var t=navigator.userAgent.toLowerCase(),n=function(){var e=navigator,t=e.platform,e=e.maxTouchPoints;if("number"==typeof e)return 1<e;if("string"==typeof t){if(e=t.toLowerCase(),/(mac|win)/i.test(e))return!1;if(/(android|iphone|ipad|ipod|arch)/i.test(e))return!0}return/(iphone|ipad|ipod|ios|android)/i.test(navigator.userAgent.toLowerCase())}(),r=!!window.top&&window!==window.top,i=e("qqbrowser"),a=e("firefox"),s=e("macintosh"),l=e("edge"),u=l&&!e("chrome"),c=u||e("trident")||e("msie"),d=e("crios"),f=e("edgios"),h=e("chrome")||d,p=!n&&/(googlebot|baiduspider|bingbot|applebot|petalbot|yandexbot|bytespider|chrome\-lighthouse|moto g power)/i.test(t);Object.assign(w,{iframe:r,pc:!n,qqBrowser:i,firefox:a,macos:s,edge:l,oldEdge:u,ie:c,iosChrome:d,iosEdge:f,chrome:h,seoBot:p,mobile:n})}(),s=window.console||{log:function(){},table:function(){},clear:function(){}},b=w.ie?(y=function(){return s.log.apply(s,arguments)},_=function(){return s.table.apply(s,arguments)},function(){return s.clear()}):(y=s.log,_=s.table,s.clear),function(t){var n,r=0<arguments.length&&void 0!==t?t:{};for(n in h)void 0===r[n]||e(h[n])!==e(r[n])&&-1===p.indexOf(n)||(h[n]=r[n]);"function"==typeof h.ondevtoolclose&&!0===h.clearIntervalWhenDevOpenTrigger&&(h.clearIntervalWhenDevOpenTrigger=!1,console.warn("【DISABLE-DEVTOOL】clearIntervalWhenDevOpenTrigger 在使用 ondevtoolclose 时无效"))}(t),h.md5&&z((r=h.tkName,i=window.location.search,a=window.location.hash,""!==(i=""===i&&""!==a?"?".concat(a.split("?")[1]):i)&&void 0!==i&&(a=RegExp("(^|&)"+r+"=([^&]*)(&|$)","i"),null!=(r=i.substr(1).match(a)))?unescape(r[2]):""))===h.md5)return n("token passed");if(h.seo&&w.seoBot)return n("seobot");er.isRunning=!0,function(e){function t(){c=!0}function n(){c=!1}var r,i,a,s,l,u,c=!1;function f(){(u[s]===a?i:r)()}(function(e,t){function n(n){return function(){e&&e();var r=n.apply(void 0,arguments);return t&&t(),r}}var r=window.alert,i=window.confirm,a=window.prompt;try{window.alert=n(r),window.confirm=n(i),window.prompt=n(a)}catch(e){}})(t,n),r=n,i=t,void 0!==(u=document).hidden?(a="hidden",l="visibilitychange",s="visibilityState"):void 0!==u.mozHidden?(a="mozHidden",l="mozvisibilitychange",s="mozVisibilityState"):void 0!==u.msHidden?(a="msHidden",l="msvisibilitychange",s="msVisibilityState"):void 0!==u.webkitHidden&&(a="webkitHidden",l="webkitvisibilitychange",s="webkitVisibilityState"),u.removeEventListener(l,f,!1),u.addEventListener(l,f,!1),B=window.setInterval(function(){if(!(e.isSuspend||c||E())){var t,n,r=d(N);try{for(r.s();!(t=r.n()).done;){var i=t.value;R[i.type]=!1,i.detect(F++)}}catch(e){r.e(e)}finally{r.f()}x(),"function"==typeof h.ondevtoolclose&&(n=D,!U()&&n&&h.ondevtoolclose())}},h.interval),M=setTimeout(function(){w.pc||P.isUsing()||j()},h.stopIntervalTime)}(er);var r,i,a,s,l=(T=function(){return er.isSuspend},window.top),u=window.parent;if(A(window),h.disableIframeParents&&l&&u&&l!==window){for(;u!==l;)A(u),u=u.parent;A(l)}return("all"===h.detectors?Object.keys(en):h.detectors).forEach(function(e){new en[e]}),n()},{isRunning:!1,isSuspend:!1,md5:z,version:"0.3.8",DetectorType:I,isDevToolOpened:U});return(J=function(){if("undefined"==typeof window||!window.document)return null;var e=document.querySelector("[disable-devtool-auto]");if(!e)return null;var t=["disable-menu","disable-select","disable-copy","disable-cut","disable-paste","clear-log"],n=["interval"],r={};return["md5","url","tk-name","detectors"].concat(t,n).forEach(function(i){var a=e.getAttribute(i);null!==a&&(-1!==n.indexOf(i)?a=parseInt(a):-1!==t.indexOf(i)?a="false"!==a:"detector"===i&&"all"!==a&&(a=a.split(" ")),r[function(e){if(-1===e.indexOf("-"))return e;var t=!1;return e.split("").map(function(e){return"-"===e?(t=!0,""):t?(t=!1,e.toUpperCase()):e}).join("")}(i)]=a)}),r}())&&er(J),er}()},558:function(e,t,n){e=n.nmd(e);var r=function(){var e=String.fromCharCode,t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",r={};function i(e,t){if(!r[e]){r[e]={};for(var n=0;n<e.length;n++)r[e][e.charAt(n)]=n}return r[e][t]}var a={compressToBase64:function(e){if(null==e)return"";var n=a._compress(e,6,function(e){return t.charAt(e)});switch(n.length%4){default:case 0:return n;case 1:return n+"===";case 2:return n+"==";case 3:return n+"="}},decompressFromBase64:function(e){return null==e?"":""==e?null:a._decompress(e.length,32,function(n){return i(t,e.charAt(n))})},compressToUTF16:function(t){return null==t?"":a._compress(t,15,function(t){return e(t+32)})+" "},decompressFromUTF16:function(e){return null==e?"":""==e?null:a._decompress(e.length,16384,function(t){return e.charCodeAt(t)-32})},compressToUint8Array:function(e){for(var t=a.compress(e),n=new Uint8Array(2*t.length),r=0,i=t.length;r<i;r++){var s=t.charCodeAt(r);n[2*r]=s>>>8,n[2*r+1]=s%256}return n},decompressFromUint8Array:function(t){if(null==t)return a.decompress(t);for(var n=Array(t.length/2),r=0,i=n.length;r<i;r++)n[r]=256*t[2*r]+t[2*r+1];var s=[];return n.forEach(function(t){s.push(e(t))}),a.decompress(s.join(""))},compressToEncodedURIComponent:function(e){return null==e?"":a._compress(e,6,function(e){return n.charAt(e)})},decompressFromEncodedURIComponent:function(e){return null==e?"":""==e?null:(e=e.replace(/ /g,"+"),a._decompress(e.length,32,function(t){return i(n,e.charAt(t))}))},compress:function(t){return a._compress(t,16,function(t){return e(t)})},_compress:function(e,t,n){if(null==e)return"";var r,i,a,s={},l={},u="",c="",d="",f=2,h=3,p=2,m=[],g=0,y=0;for(a=0;a<e.length;a+=1)if(u=e.charAt(a),Object.prototype.hasOwnProperty.call(s,u)||(s[u]=h++,l[u]=!0),c=d+u,Object.prototype.hasOwnProperty.call(s,c))d=c;else{if(Object.prototype.hasOwnProperty.call(l,d)){if(256>d.charCodeAt(0)){for(r=0;r<p;r++)g<<=1,y==t-1?(y=0,m.push(n(g)),g=0):y++;for(r=0,i=d.charCodeAt(0);r<8;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1}else{for(r=0,i=1;r<p;r++)g=g<<1|i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i=0;for(r=0,i=d.charCodeAt(0);r<16;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1}0==--f&&(f=Math.pow(2,p),p++),delete l[d]}else for(r=0,i=s[d];r<p;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1;0==--f&&(f=Math.pow(2,p),p++),s[c]=h++,d=String(u)}if(""!==d){if(Object.prototype.hasOwnProperty.call(l,d)){if(256>d.charCodeAt(0)){for(r=0;r<p;r++)g<<=1,y==t-1?(y=0,m.push(n(g)),g=0):y++;for(r=0,i=d.charCodeAt(0);r<8;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1}else{for(r=0,i=1;r<p;r++)g=g<<1|i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i=0;for(r=0,i=d.charCodeAt(0);r<16;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1}0==--f&&(f=Math.pow(2,p),p++),delete l[d]}else for(r=0,i=s[d];r<p;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1;0==--f&&(f=Math.pow(2,p),p++)}for(r=0,i=2;r<p;r++)g=g<<1|1&i,y==t-1?(y=0,m.push(n(g)),g=0):y++,i>>=1;for(;;){if(g<<=1,y==t-1){m.push(n(g));break}y++}return m.join("")},decompress:function(e){return null==e?"":""==e?null:a._decompress(e.length,32768,function(t){return e.charCodeAt(t)})},_decompress:function(t,n,r){var i,a,s,l,u,c,d,f=[],h=4,p=4,m=3,g="",y=[],_={val:r(0),position:n,index:1};for(i=0;i<3;i+=1)f[i]=i;for(s=0,u=4,c=1;c!=u;)l=_.val&_.position,_.position>>=1,0==_.position&&(_.position=n,_.val=r(_.index++)),s|=+(l>0)*c,c<<=1;switch(s){case 0:for(s=0,u=256,c=1;c!=u;)l=_.val&_.position,_.position>>=1,0==_.position&&(_.position=n,_.val=r(_.index++)),s|=+(l>0)*c,c<<=1;d=e(s);break;case 1:for(s=0,u=65536,c=1;c!=u;)l=_.val&_.position,_.position>>=1,0==_.position&&(_.position=n,_.val=r(_.index++)),s|=+(l>0)*c,c<<=1;d=e(s);break;case 2:return""}for(f[3]=d,a=d,y.push(d);;){if(_.index>t)return"";for(s=0,u=Math.pow(2,m),c=1;c!=u;)l=_.val&_.position,_.position>>=1,0==_.position&&(_.position=n,_.val=r(_.index++)),s|=+(l>0)*c,c<<=1;switch(d=s){case 0:for(s=0,u=256,c=1;c!=u;)l=_.val&_.position,_.position>>=1,0==_.position&&(_.position=n,_.val=r(_.index++)),s|=+(l>0)*c,c<<=1;f[p++]=e(s),d=p-1,h--;break;case 1:for(s=0,u=65536,c=1;c!=u;)l=_.val&_.position,_.position>>=1,0==_.position&&(_.position=n,_.val=r(_.index++)),s|=+(l>0)*c,c<<=1;f[p++]=e(s),d=p-1,h--;break;case 2:return y.join("")}if(0==h&&(h=Math.pow(2,m),m++),f[d])g=f[d];else{if(d!==p)return null;g=a+a.charAt(0)}y.push(g),f[p++]=a+g.charAt(0),h--,a=g,0==h&&(h=Math.pow(2,m),m++)}}};return a}();"function"==typeof define&&define.amd?define(function(){return r}):null!=e?e.exports=r:"undefined"!=typeof angular&&null!=angular&&angular.module("LZString",[]).factory("LZString",function(){return r})},231:function(e,t){"use strict";t.default=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n}}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var a=t[r]={id:r,loaded:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.loaded=!0,a.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=(()=>{if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}})(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),n.rv=()=>"1.3.2",n.ruid="bundler=rspack@1.3.2",(()=>{"use strict";let e,t,r,i,a,s,l,u,c,d,f,h,p,m,g,y,_,b,w,x,k;function S(e){let t=Object.create(null);for(let n of e.split(","))t[n]=1;return e=>e in t}let E={},T=[],A=()=>{},O=()=>!1,C=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&(e.charCodeAt(2)>122||97>e.charCodeAt(2)),I=e=>e.startsWith("onUpdate:"),D=Object.assign,R=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},U=Object.prototype.hasOwnProperty,L=(e,t)=>U.call(e,t),P=Array.isArray,B=e=>"[object Map]"===q(e),M=e=>"[object Set]"===q(e),N=e=>"[object Date]"===q(e),F=e=>"[object RegExp]"===q(e),j=e=>"function"==typeof e,z=e=>"string"==typeof e,G=e=>"symbol"==typeof e,V=e=>null!==e&&"object"==typeof e,H=e=>(V(e)||j(e))&&j(e.then)&&j(e.catch),W=Object.prototype.toString,q=e=>W.call(e),K=e=>q(e).slice(8,-1),J=e=>"[object Object]"===q(e),Z=e=>z(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,$=S(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Y=e=>{let t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Q=/-(\w)/g,X=Y(e=>e.replace(Q,(e,t)=>t?t.toUpperCase():"")),ee=/\B([A-Z])/g,et=Y(e=>e.replace(ee,"-$1").toLowerCase()),en=Y(e=>e.charAt(0).toUpperCase()+e.slice(1)),er=Y(e=>e?`on${en(e)}`:""),ei=(e,t)=>!Object.is(e,t),ea=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},es=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},eo=e=>{let t=parseFloat(e);return isNaN(t)?e:t},el=e=>{let t=z(e)?Number(e):NaN;return isNaN(t)?e:t},eu=()=>e||(e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n.g?n.g:{});function ec(e){if(P(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=z(r)?function(e){let t={};return e.replace(eh,"").split(ed).forEach(e=>{if(e){let n=e.split(ef);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}(r):ec(r);if(i)for(let e in i)t[e]=i[e]}return t}if(z(e)||V(e))return e}let ed=/;(?![^(]*\))/g,ef=/:([^]+)/,eh=/\/\*[^]*?\*\//g;function ep(e){let t="";if(z(e))t=e;else if(P(e))for(let n=0;n<e.length;n++){let r=ep(e[n]);r&&(t+=r+" ")}else if(V(e))for(let n in e)e[n]&&(t+=n+" ");return t.trim()}let ev=S("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly"),em=e=>!!(e&&!0===e.__v_isRef),eg=e=>z(e)?e:null==e?"":P(e)||V(e)&&(e.toString===W||!j(e.toString))?em(e)?eg(e.value):JSON.stringify(e,ey,2):String(e),ey=(e,t)=>{if(em(t))return ey(e,t.value);if(B(t))return{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[e_(t,r)+" =>"]=n,e),{})};if(M(t))return{[`Set(${t.size})`]:[...t.values()].map(e=>e_(e))};if(G(t))return e_(t);if(V(t)&&!P(t)&&!J(t))return String(t);return t},e_=(e,t="")=>{var n;return G(e)?`Symbol(${null!=(n=e.description)?n:t})`:e};class eb{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=t,!e&&t&&(this.index=(t.scopes||(t.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){let e,t;if(this._isPaused=!0,this.scopes)for(e=0,t=this.scopes.length;e<t;e++)this.scopes[e].pause();for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){let e,t;if(this._isPaused=!1,this.scopes)for(e=0,t=this.scopes.length;e<t;e++)this.scopes[e].resume();for(e=0,t=this.effects.length;e<t;e++)this.effects[e].resume()}}run(e){if(this._active){let n=t;try{return t=this,e()}finally{t=n}}}on(){t=this}off(){t=this.parent}stop(e){if(this._active){let t,n;for(t=0,this._active=!1,n=this.effects.length;t<n;t++)this.effects[t].stop();for(t=0,this.effects.length=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}}let ew=new WeakSet;class ex{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,t&&t.active&&t.effects.push(this)}pause(){this.flags|=64}resume(){64&this.flags&&(this.flags&=-65,ew.has(this)&&(ew.delete(this),this.trigger()))}notify(){(!(2&this.flags)||32&this.flags)&&(8&this.flags||eS(this))}run(){if(!(1&this.flags))return this.fn();this.flags|=2,eP(this),eT(this);let e=r,t=eD;r=this,eD=!0;try{return this.fn()}finally{eA(this),r=e,eD=t,this.flags&=-3}}stop(){if(1&this.flags){for(let e=this.deps;e;e=e.nextDep)eI(e);this.deps=this.depsTail=void 0,eP(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){64&this.flags?ew.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){eO(this)&&this.run()}get dirty(){return eO(this)}}let ek=0;function eS(e,t=!1){if(e.flags|=8,t){e.next=a,a=e;return}e.next=i,i=e}function eE(){let e;if(!(--ek>0)){if(a){let e=a;for(a=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}for(;i;){let t=i;for(i=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,1&t.flags)try{t.trigger()}catch(t){e||(e=t)}t=n}}if(e)throw e}}function eT(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function eA(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;-1===r.version?(r===n&&(n=e),eI(r),function(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function eO(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(eC(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function eC(e){if(4&e.flags&&!(16&e.flags)||(e.flags&=-17,e.globalVersion===eB))return;e.globalVersion=eB;let t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!eO(e)){e.flags&=-3;return}let n=r,i=eD;r=e,eD=!0;try{eT(e);let n=e.fn(e._value);(0===t.version||ei(n,e._value))&&(e._value=n,t.version++)}catch(e){throw t.version++,e}finally{r=n,eD=i,eA(e),e.flags&=-3}}function eI(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)eI(e,!0)}t||--n.sc||!n.map||n.map.delete(n.key)}let eD=!0,eR=[];function eU(){eR.push(eD),eD=!1}function eL(){let e=eR.pop();eD=void 0===e||e}function eP(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=r;r=void 0;try{t()}finally{r=e}}}let eB=0;class eM{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class eN{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0}track(e){if(!r||!eD||r===this.computed)return;let t=this.activeLink;if(void 0===t||t.sub!==r)t=this.activeLink=new eM(r,this),r.deps?(t.prevDep=r.depsTail,r.depsTail.nextDep=t,r.depsTail=t):r.deps=r.depsTail=t,function e(t){if(t.dep.sc++,4&t.sub.flags){let n=t.dep.computed;if(n&&!t.dep.subs){n.flags|=20;for(let t=n.deps;t;t=t.nextDep)e(t)}let r=t.dep.subs;r!==t&&(t.prevSub=r,r&&(r.nextSub=t)),t.dep.subs=t}}(t);else if(-1===t.version&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=r.depsTail,t.nextDep=void 0,r.depsTail.nextDep=t,r.depsTail=t,r.deps===t&&(r.deps=e)}return t}trigger(e){this.version++,eB++,this.notify(e)}notify(e){ek++;try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{eE()}}}let eF=new WeakMap,ej=Symbol(""),ez=Symbol(""),eG=Symbol("");function eV(e,t,n){if(eD&&r){let t=eF.get(e);t||eF.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new eN),r.map=t,r.key=n),r.track()}}function eH(e,t,n,r,i,a){let s=eF.get(e);if(!s)return void eB++;let l=e=>{e&&e.trigger()};if(ek++,"clear"===t)s.forEach(l);else{let i=P(e),a=i&&Z(n);if(i&&"length"===n){let e=Number(r);s.forEach((t,n)=>{("length"===n||n===eG||!G(n)&&n>=e)&&l(t)})}else switch((void 0!==n||s.has(void 0))&&l(s.get(n)),a&&l(s.get(eG)),t){case"add":i?a&&l(s.get("length")):(l(s.get(ej)),B(e)&&l(s.get(ez)));break;case"delete":!i&&(l(s.get(ej)),B(e)&&l(s.get(ez)));break;case"set":B(e)&&l(s.get(ej))}}eE()}function eW(e){let t=ty(e);return t===e?t:(eV(t,"iterate",eG),tm(e)?t:t.map(t_))}function eq(e){return eV(e=ty(e),"iterate",eG),e}let eK={__proto__:null,[Symbol.iterator](){return eJ(this,Symbol.iterator,t_)},concat(...e){return eW(this).concat(...e.map(e=>P(e)?eW(e):e))},entries(){return eJ(this,"entries",e=>(e[1]=t_(e[1]),e))},every(e,t){return e$(this,"every",e,t,void 0,arguments)},filter(e,t){return e$(this,"filter",e,t,e=>e.map(t_),arguments)},find(e,t){return e$(this,"find",e,t,t_,arguments)},findIndex(e,t){return e$(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return e$(this,"findLast",e,t,t_,arguments)},findLastIndex(e,t){return e$(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return e$(this,"forEach",e,t,void 0,arguments)},includes(...e){return eQ(this,"includes",e)},indexOf(...e){return eQ(this,"indexOf",e)},join(e){return eW(this).join(e)},lastIndexOf(...e){return eQ(this,"lastIndexOf",e)},map(e,t){return e$(this,"map",e,t,void 0,arguments)},pop(){return eX(this,"pop")},push(...e){return eX(this,"push",e)},reduce(e,...t){return eY(this,"reduce",e,t)},reduceRight(e,...t){return eY(this,"reduceRight",e,t)},shift(){return eX(this,"shift")},some(e,t){return e$(this,"some",e,t,void 0,arguments)},splice(...e){return eX(this,"splice",e)},toReversed(){return eW(this).toReversed()},toSorted(e){return eW(this).toSorted(e)},toSpliced(...e){return eW(this).toSpliced(...e)},unshift(...e){return eX(this,"unshift",e)},values(){return eJ(this,"values",t_)}};function eJ(e,t,n){let r=eq(e),i=r[t]();return r===e||tm(e)||(i._next=i.next,i.next=()=>{let e=i._next();return e.value&&(e.value=n(e.value)),e}),i}let eZ=Array.prototype;function e$(e,t,n,r,i,a){let s=eq(e),l=s!==e&&!tm(e),u=s[t];if(u!==eZ[t]){let t=u.apply(e,a);return l?t_(t):t}let c=n;s!==e&&(l?c=function(t,r){return n.call(this,t_(t),r,e)}:n.length>2&&(c=function(t,r){return n.call(this,t,r,e)}));let d=u.call(s,c,r);return l&&i?i(d):d}function eY(e,t,n,r){let i=eq(e),a=n;return i!==e&&(tm(e)?n.length>3&&(a=function(t,r,i){return n.call(this,t,r,i,e)}):a=function(t,r,i){return n.call(this,t,t_(r),i,e)}),i[t](a,...r)}function eQ(e,t,n){let r=ty(e);eV(r,"iterate",eG);let i=r[t](...n);return(-1===i||!1===i)&&tg(n[0])?(n[0]=ty(n[0]),r[t](...n)):i}function eX(e,t,n=[]){eU(),ek++;let r=ty(e)[t].apply(e,n);return eE(),eL(),r}let e0=S("__proto__,__v_isRef,__isVue"),e1=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>"arguments"!==e&&"caller"!==e).map(e=>Symbol[e]).filter(G));function e2(e){G(e)||(e=String(e));let t=ty(this);return eV(t,"has",e),t.hasOwnProperty(e)}class e5{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if("__v_skip"===t)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if("__v_isReactive"===t)return!r;if("__v_isReadonly"===t)return r;if("__v_isShallow"===t)return i;if("__v_raw"===t)return n===(r?i?tu:tl:i?to:ts).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=P(e);if(!r){let e;if(a&&(e=eK[t]))return e;if("hasOwnProperty"===t)return e2}let s=Reflect.get(e,t,tw(e)?e:n);return(G(t)?e1.has(t):e0(t))||(r||eV(e,"get",t),i)?s:tw(s)?a&&Z(t)?s:s.value:V(s)?r?tf(s):tc(s):s}}class e3 extends e5{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t];if(!this._isShallow){let t=tv(i);if(tm(n)||tv(n)||(i=ty(i),n=ty(n)),!P(e)&&tw(i)&&!tw(n))if(t)return!1;else return i.value=n,!0}let a=P(e)&&Z(t)?Number(t)<e.length:L(e,t),s=Reflect.set(e,t,n,tw(e)?e:r);return e===ty(r)&&(a?ei(n,i)&&eH(e,"set",t,n,i):eH(e,"add",t,n)),s}deleteProperty(e,t){let n=L(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&eH(e,"delete",t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return G(t)&&e1.has(t)||eV(e,"has",t),n}ownKeys(e){return eV(e,"iterate",P(e)?"length":ej),Reflect.ownKeys(e)}}class e6 extends e5{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}}let e4=new e3,e8=new e6,e9=new e3(!0),e7=e=>e,te=e=>Reflect.getPrototypeOf(e);function tt(e){return function(...t){return"delete"!==e&&("clear"===e?void 0:this)}}function tn(e,t){let n=function(e,t){let n={get(n){let r=this.__v_raw,i=ty(r),a=ty(n);e||(ei(n,a)&&eV(i,"get",n),eV(i,"get",a));let{has:s}=te(i),l=t?e7:e?tb:t_;return s.call(i,n)?l(r.get(n)):s.call(i,a)?l(r.get(a)):void(r!==i&&r.get(n))},get size(){let t=this.__v_raw;return e||eV(ty(t),"iterate",ej),Reflect.get(t,"size",t)},has(t){let n=this.__v_raw,r=ty(n),i=ty(t);return e||(ei(t,i)&&eV(r,"has",t),eV(r,"has",i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,s=ty(a),l=t?e7:e?tb:t_;return e||eV(s,"iterate",ej),a.forEach((e,t)=>n.call(r,l(e),l(t),i))}};return D(n,e?{add:tt("add"),set:tt("set"),delete:tt("delete"),clear:tt("clear")}:{add(e){t||tm(e)||tv(e)||(e=ty(e));let n=ty(this);return te(n).has.call(n,e)||(n.add(e),eH(n,"add",e,e)),this},set(e,n){t||tm(n)||tv(n)||(n=ty(n));let r=ty(this),{has:i,get:a}=te(r),s=i.call(r,e);s||(e=ty(e),s=i.call(r,e));let l=a.call(r,e);return r.set(e,n),s?ei(n,l)&&eH(r,"set",e,n,l):eH(r,"add",e,n),this},delete(e){let t=ty(this),{has:n,get:r}=te(t),i=n.call(t,e);i||(e=ty(e),i=n.call(t,e));let a=r?r.call(t,e):void 0,s=t.delete(e);return i&&eH(t,"delete",e,void 0,a),s},clear(){let e=ty(this),t=0!==e.size,n=e.clear();return t&&eH(e,"clear",void 0,void 0,void 0),n}}),["keys","values","entries",Symbol.iterator].forEach(r=>{n[r]=function(...n){let i=this.__v_raw,a=ty(i),s=B(a),l="entries"===r||r===Symbol.iterator&&s,u=i[r](...n),c=t?e7:e?tb:t_;return e||eV(a,"iterate","keys"===r&&s?ez:ej),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:l?[c(e[0]),c(e[1])]:c(e),done:t}},[Symbol.iterator](){return this}}}}),n}(e,t);return(t,r,i)=>"__v_isReactive"===r?!e:"__v_isReadonly"===r?e:"__v_raw"===r?t:Reflect.get(L(n,r)&&r in t?n:t,r,i)}let tr={get:tn(!1,!1)},ti={get:tn(!1,!0)},ta={get:tn(!0,!1)},ts=new WeakMap,to=new WeakMap,tl=new WeakMap,tu=new WeakMap;function tc(e){return tv(e)?e:th(e,!1,e4,tr,ts)}function td(e){return th(e,!1,e9,ti,to)}function tf(e){return th(e,!0,e8,ta,tl)}function th(e,t,n,r,i){if(!V(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;let a=i.get(e);if(a)return a;let s=e.__v_skip||!Object.isExtensible(e)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}(K(e));if(0===s)return e;let l=new Proxy(e,2===s?r:n);return i.set(e,l),l}function tp(e){return tv(e)?tp(e.__v_raw):!!(e&&e.__v_isReactive)}function tv(e){return!!(e&&e.__v_isReadonly)}function tm(e){return!!(e&&e.__v_isShallow)}function tg(e){return!!e&&!!e.__v_raw}function ty(e){let t=e&&e.__v_raw;return t?ty(t):e}let t_=e=>V(e)?tc(e):e,tb=e=>V(e)?tf(e):e;function tw(e){return!!e&&!0===e.__v_isRef}function tx(e){return tk(e,!1)}function tk(e,t){return tw(e)?e:new tS(e,t)}class tS{constructor(e,t){this.dep=new eN,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:ty(e),this._value=t?e:t_(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||tm(e)||tv(e);ei(e=n?e:ty(e),t)&&(this._rawValue=e,this._value=n?e:t_(e),this.dep.trigger())}}function tE(e){return tw(e)?e.value:e}let tT={get:(e,t,n)=>"__v_raw"===t?e:tE(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return tw(i)&&!tw(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function tA(e){return tp(e)?e:new Proxy(e,tT)}class tO{constructor(e){this.__v_isRef=!0,this._value=void 0;let t=this.dep=new eN,{get:n,set:r}=e(t.track.bind(t),t.trigger.bind(t));this._get=n,this._set=r}get value(){return this._value=this._get()}set value(e){this._set(e)}}class tC{constructor(e,t,n){this._object=e,this._key=t,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0}get value(){let e=this._object[this._key];return this._value=void 0===e?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){return function(e,t){let n=eF.get(e);return n&&n.get(t)}(ty(this._object),this._key)}}class tI{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new eN(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=eB-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(8&this.flags)&&r!==this)return eS(this,!0),!0}get value(){let e=this.dep.track();return eC(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}}let tD={},tR=new WeakMap;function tU(e,t=1/0,n){if(t<=0||!V(e)||e.__v_skip||(n=n||new Set).has(e))return e;if(n.add(e),t--,tw(e))tU(e.value,t,n);else if(P(e))for(let r=0;r<e.length;r++)tU(e[r],t,n);else if(M(e)||B(e))e.forEach(e=>{tU(e,t,n)});else if(J(e)){for(let r in e)tU(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&tU(e[r],t,n)}return e}let tL=!1;function tP(e,t,n,r){try{return r?e(...r):e()}catch(e){tM(e,t,n)}}function tB(e,t,n,r){if(j(e)){let i=tP(e,t,n,r);return i&&H(i)&&i.catch(e=>{tM(e,t,n)}),i}if(P(e)){let i=[];for(let a=0;a<e.length;a++)i.push(tB(e[a],t,n,r));return i}}function tM(e,t,n,r=!0){let i=t?t.vnode:null,{errorHandler:a,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||E;if(t){let r=t.parent,i=t.proxy,s=`https://vuejs.org/error-reference/#runtime-${n}`;for(;r;){let t=r.ec;if(t){for(let n=0;n<t.length;n++)if(!1===t[n](e,i,s))return}r=r.parent}if(a){eU(),tP(a,null,10,[e,i,s]),eL();return}}!function(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}(e,0,0,r,s)}let tN=[],tF=-1,tj=[],tz=null,tG=0,tV=Promise.resolve(),tH=null;function tW(e){let t=tH||tV;return e?t.then(this?e.bind(this):e):t}function tq(e){if(!(1&e.flags)){let t=tY(e),n=tN[tN.length-1];!n||!(2&e.flags)&&t>=tY(n)?tN.push(e):tN.splice(function(e){let t=tF+1,n=tN.length;for(;t<n;){let r=t+n>>>1,i=tN[r],a=tY(i);a<e||a===e&&2&i.flags?t=r+1:n=r}return t}(t),0,e),e.flags|=1,tK()}}function tK(){tH||(tH=tV.then(function e(t){try{for(tF=0;tF<tN.length;tF++){let e=tN[tF];e&&!(8&e.flags)&&(4&e.flags&&(e.flags&=-2),tP(e,e.i,e.i?15:14),4&e.flags||(e.flags&=-2))}}finally{for(;tF<tN.length;tF++){let e=tN[tF];e&&(e.flags&=-2)}tF=-1,tN.length=0,t$(t),tH=null,(tN.length||tj.length)&&e(t)}}))}function tJ(e){P(e)?tj.push(...e):tz&&-1===e.id?tz.splice(tG+1,0,e):1&e.flags||(tj.push(e),e.flags|=1),tK()}function tZ(e,t,n=tF+1){for(;n<tN.length;n++){let t=tN[n];if(t&&2&t.flags){if(e&&t.id!==e.uid)continue;tN.splice(n,1),n--,4&t.flags&&(t.flags&=-2),t(),4&t.flags||(t.flags&=-2)}}}function t$(e){if(tj.length){let e=[...new Set(tj)].sort((e,t)=>tY(e)-tY(t));if(tj.length=0,tz)return void tz.push(...e);for(tG=0,tz=e;tG<tz.length;tG++){let e=tz[tG];4&e.flags&&(e.flags&=-2),8&e.flags||e(),e.flags&=-2}tz=null,tG=0}}let tY=e=>null==e.id?2&e.flags?-1:1/0:e.id,tQ=[],tX=null,t0=null;function t1(e){let t=tX;return tX=e,t0=e&&e.type.__scopeId||null,t}function t2(e,t=tX,n){if(!t||e._n)return e;let r=(...n)=>{let i;r._d&&it(-1);let a=t1(t);try{i=e(...n)}finally{t1(a),r._d&&it(1)}return i};return r._n=!0,r._c=!0,r._d=!0,r}function t5(e,t){if(null===tX)return e;let n=iU(tX),r=e.dirs||(e.dirs=[]);for(let e=0;e<t.length;e++){let[i,a,s,l=E]=t[e];i&&(j(i)&&(i={mounted:i,updated:i}),i.deep&&tU(a),r.push({dir:i,instance:n,value:a,oldValue:void 0,arg:s,modifiers:l}))}return e}function t3(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let s=0;s<i.length;s++){let l=i[s];a&&(l.oldValue=a[s].value);let u=l.dir[r];u&&(eU(),tB(u,n,8,[e.el,l,e,t]),eL())}}let t6=Symbol("_vte"),t4=e=>e.__isTeleport,t8=e=>e&&(e.disabled||""===e.disabled),t9=e=>e&&(e.defer||""===e.defer),t7=e=>"undefined"!=typeof SVGElement&&e instanceof SVGElement,ne=e=>"function"==typeof MathMLElement&&e instanceof MathMLElement,nt=(e,t)=>{let n=e&&e.to;return z(n)?t?t(n):null:n},nn={name:"Teleport",__isTeleport:!0,process(e,t,n,r,i,a,s,l,u,c){let{mc:d,pc:f,pbc:h,o:{insert:p,querySelector:m,createText:g,createComment:y}}=c,_=t8(t.props),{shapeFlag:b,children:w,dynamicChildren:x}=t;if(null==e){let e=t.el=g(""),c=t.anchor=g("");p(e,n,r),p(c,n,r);let f=(e,t)=>{16&b&&(i&&i.isCE&&(i.ce._teleportTarget=e),d(w,e,t,i,a,s,l,u))},h=()=>{let e=t.target=nt(t.props,m),n=na(e,t,g,p);e&&("svg"!==s&&t7(e)?s="svg":"mathml"!==s&&ne(e)&&(s="mathml"),_||(f(e,n),ni(t,!1)))};_&&(f(n,c),ni(t,!0)),t9(t.props)?rI(()=>{h(),t.el.__isMounted=!0},a):h()}else{if(t9(t.props)&&!e.el.__isMounted)return void rI(()=>{nn.process(e,t,n,r,i,a,s,l,u,c),delete e.el.__isMounted},a);t.el=e.el,t.targetStart=e.targetStart;let d=t.anchor=e.anchor,p=t.target=e.target,g=t.targetAnchor=e.targetAnchor,y=t8(e.props),b=y?n:p,w=y?d:g;if("svg"===s||t7(p)?s="svg":("mathml"===s||ne(p))&&(s="mathml"),x?(h(e.dynamicChildren,x,b,i,a,s,l),rL(e,t,!0)):u||f(e,t,b,w,i,a,s,l,!1),_)y?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):nr(t,n,d,c,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){let e=t.target=nt(t.props,m);e&&nr(t,e,null,c,0)}else y&&nr(t,p,g,c,1);ni(t,_)}},remove(e,t,n,{um:r,o:{remove:i}},a){let{shapeFlag:s,children:l,anchor:u,targetStart:c,targetAnchor:d,target:f,props:h}=e;if(f&&(i(c),i(d)),a&&i(u),16&s){let e=a||!t8(h);for(let i=0;i<l.length;i++){let a=l[i];r(a,t,n,e,!!a.dynamicChildren)}}},move:nr,hydrate:function(e,t,n,r,i,a,{o:{nextSibling:s,parentNode:l,querySelector:u,insert:c,createText:d}},f){let h=t.target=nt(t.props,u);if(h){let u=t8(t.props),p=h._lpa||h.firstChild;if(16&t.shapeFlag)if(u)t.anchor=f(s(e),t,l(e),n,r,i,a),t.targetStart=p,t.targetAnchor=p&&s(p);else{t.anchor=s(e);let l=p;for(;l;){if(l&&8===l.nodeType){if("teleport start anchor"===l.data)t.targetStart=l;else if("teleport anchor"===l.data){t.targetAnchor=l,h._lpa=t.targetAnchor&&s(t.targetAnchor);break}}l=s(l)}t.targetAnchor||na(h,t,d,c),f(p&&s(p),t,h,n,r,i,a)}ni(t,u)}return t.anchor&&s(t.anchor)}};function nr(e,t,n,{o:{insert:r},m:i},a=2){0===a&&r(e.targetAnchor,t,n);let{el:s,anchor:l,shapeFlag:u,children:c,props:d}=e,f=2===a;if(f&&r(s,t,n),(!f||t8(d))&&16&u)for(let e=0;e<c.length;e++)i(c[e],t,n,2);f&&r(l,t,n)}function ni(e,t){let n=e.ctx;if(n&&n.ut){let r,i;for(t?(r=e.el,i=e.anchor):(r=e.targetStart,i=e.targetAnchor);r&&r!==i;)1===r.nodeType&&r.setAttribute("data-v-owner",n.uid),r=r.nextSibling;n.ut()}}function na(e,t,n,r){let i=t.targetStart=n(""),a=t.targetAnchor=n("");return i[t6]=a,e&&(r(i,e),r(a,e)),a}let ns=Symbol("_leaveCb"),no=Symbol("_enterCb"),nl=[Function,Array],nu={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:nl,onEnter:nl,onAfterEnter:nl,onEnterCancelled:nl,onBeforeLeave:nl,onLeave:nl,onAfterLeave:nl,onLeaveCancelled:nl,onBeforeAppear:nl,onAppear:nl,onAfterAppear:nl,onAppearCancelled:nl},nc=e=>{let t=e.subTree;return t.component?nc(t.component):t};function nd(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==r3){t=n;break}}return t}let nf={name:"BaseTransition",props:nu,setup(e,{slots:t}){let n=iS(),r=function(){let e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return nz(()=>{e.isMounted=!0}),nH(()=>{e.isUnmounting=!0}),e}();return()=>{let i=t.default&&function e(t,n=!1,r){let i=[],a=0;for(let s=0;s<t.length;s++){let l=t[s],u=null==r?l.key:String(r)+String(null!=l.key?l.key:s);l.type===r2?(128&l.patchFlag&&a++,i=i.concat(e(l.children,n,u))):(n||l.type!==r3)&&i.push(null!=u?ih(l,{key:u}):l)}if(a>1)for(let e=0;e<i.length;e++)i[e].patchFlag=-2;return i}(t.default(),!0);if(!i||!i.length)return;let a=nd(i),s=ty(e),{mode:l}=s;if(r.isLeaving)return nv(a);let u=nm(a);if(!u)return nv(a);let c=np(u,s,r,n,e=>c=e);u.type!==r3&&ng(u,c);let d=n.subTree&&nm(n.subTree);if(d&&d.type!==r3&&!io(u,d)&&nc(n).type!==r3){let e=np(d,s,r,n);if(ng(d,e),"out-in"===l&&u.type!==r3)return r.isLeaving=!0,e.afterLeave=()=>{r.isLeaving=!1,8&n.job.flags||n.update(),delete e.afterLeave,d=void 0},nv(a);"in-out"===l&&u.type!==r3?e.delayLeave=(e,t,n)=>{nh(r,d)[String(d.key)]=d,e[ns]=()=>{t(),e[ns]=void 0,delete c.delayedLeave,d=void 0},c.delayedLeave=()=>{n(),delete c.delayedLeave,d=void 0}}:d=void 0}else d&&(d=void 0);return a}}};function nh(e,t){let{leavingVNodes:n}=e,r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function np(e,t,n,r,i){let{appear:a,mode:s,persisted:l=!1,onBeforeEnter:u,onEnter:c,onAfterEnter:d,onEnterCancelled:f,onBeforeLeave:h,onLeave:p,onAfterLeave:m,onLeaveCancelled:g,onBeforeAppear:y,onAppear:_,onAfterAppear:b,onAppearCancelled:w}=t,x=String(e.key),k=nh(n,e),S=(e,t)=>{e&&tB(e,r,9,t)},E=(e,t)=>{let n=t[1];S(e,t),P(e)?e.every(e=>e.length<=1)&&n():e.length<=1&&n()},T={mode:s,persisted:l,beforeEnter(t){let r=u;if(!n.isMounted)if(!a)return;else r=y||u;t[ns]&&t[ns](!0);let i=k[x];i&&io(e,i)&&i.el[ns]&&i.el[ns](),S(r,[t])},enter(e){let t=c,r=d,i=f;if(!n.isMounted)if(!a)return;else t=_||c,r=b||d,i=w||f;let s=!1,l=e[no]=t=>{s||(s=!0,t?S(i,[e]):S(r,[e]),T.delayedLeave&&T.delayedLeave(),e[no]=void 0)};t?E(t,[e,l]):l()},leave(t,r){let i=String(e.key);if(t[no]&&t[no](!0),n.isUnmounting)return r();S(h,[t]);let a=!1,s=t[ns]=n=>{a||(a=!0,r(),n?S(g,[t]):S(m,[t]),t[ns]=void 0,k[i]===e&&delete k[i])};k[i]=e,p?E(p,[t,s]):s()},clone(e){let a=np(e,t,n,r,i);return i&&i(a),a}};return T}function nv(e){if(nI(e))return(e=ih(e)).children=null,e}function nm(e){if(!nI(e))return t4(e.type)&&e.children?nd(e.children):e;let{shapeFlag:t,children:n}=e;if(n){if(16&t)return n[0];if(32&t&&j(n.default))return n.default()}}function ng(e,t){6&e.shapeFlag&&e.component?(e.transition=t,ng(e.component.subTree,t)):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function ny(e,t){return j(e)?D({name:e.name},t,{setup:e}):e}function n_(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function nb(e,t,n,r,i=!1){if(P(e))return void e.forEach((e,a)=>nb(e,t&&(P(t)?t[a]:t),n,r,i));if(nC(r)&&!i){512&r.shapeFlag&&r.type.__asyncResolved&&r.component.subTree.component&&nb(e,t,n,r.component.subTree);return}let a=4&r.shapeFlag?iU(r.component):r.el,s=i?null:a,{i:l,r:u}=e,c=t&&t.r,d=l.refs===E?l.refs={}:l.refs,f=l.setupState,h=ty(f),p=f===E?()=>!1:e=>L(h,e);if(null!=c&&c!==u&&(z(c)?(d[c]=null,p(c)&&(f[c]=null)):tw(c)&&(c.value=null)),j(u))tP(u,l,12,[s,d]);else{let t=z(u),r=tw(u);if(t||r){let l=()=>{if(e.f){let n=t?p(u)?f[u]:d[u]:u.value;i?P(n)&&R(n,a):P(n)?n.includes(a)||n.push(a):t?(d[u]=[a],p(u)&&(f[u]=d[u])):(u.value=[a],e.k&&(d[e.k]=u.value))}else t?(d[u]=s,p(u)&&(f[u]=s)):r&&(u.value=s,e.k&&(d[e.k]=s))};s?(l.id=-1,rI(l,n)):l()}}}let nw=!1,nx=()=>{nw||(console.error("Hydration completed but contains mismatches."),nw=!0)},nk=e=>e.namespaceURI.includes("svg")&&"foreignObject"!==e.tagName,nS=e=>e.namespaceURI.includes("MathML"),nE=e=>{if(1===e.nodeType){if(nk(e))return"svg";if(nS(e))return"mathml"}},nT=e=>8===e.nodeType,nA="data-allow-mismatch";function nO(e,t){if(0===t||1===t)for(;e&&!e.hasAttribute(nA);)e=e.parentElement;let n=e&&e.getAttribute(nA);if(null==n)return!1;{if(""===n)return!0;let e=n.split(",");return!!(0===t&&e.includes("children"))||n.split(",").includes(null[t])}}eu().requestIdleCallback||(e=>setTimeout(e,1)),eu().cancelIdleCallback||(e=>clearTimeout(e));let nC=e=>!!e.type.__asyncLoader,nI=e=>e.type.__isKeepAlive,nD={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){let n=iS(),r=n.ctx;if(!r.renderer)return()=>{let e=t.default&&t.default();return e&&1===e.length?e[0]:e};let i=new Map,a=new Set,s=null,l=n.suspense,{renderer:{p:u,m:c,um:d,o:{createElement:f}}}=r,h=f("div");function p(e){nB(e),d(e,n,l,!0)}function m(e){i.forEach((t,n)=>{let r=iB(t.type);r&&!e(r)&&g(n)})}function g(e){let t=i.get(e);!t||s&&io(t,s)?s&&nB(s):p(t),i.delete(e),a.delete(e)}r.activate=(e,t,n,r,i)=>{let a=e.component;c(e,t,n,0,l),u(a.vnode,e,t,n,a,l,r,e.slotScopeIds,i),rI(()=>{a.isDeactivated=!1,a.a&&ea(a.a);let t=e.props&&e.props.onVnodeMounted;t&&ib(t,a.parent,e)},l)},r.deactivate=e=>{let t=e.component;rP(t.m),rP(t.a),c(e,h,null,1,l),rI(()=>{t.da&&ea(t.da);let n=e.props&&e.props.onVnodeUnmounted;n&&ib(n,t.parent,e),t.isDeactivated=!0},l)},rF(()=>[e.include,e.exclude],([e,t])=>{e&&m(t=>nR(e,t)),t&&m(e=>!nR(t,e))},{flush:"post",deep:!0});let y=null,_=()=>{null!=y&&(rY(n.subTree.type)?rI(()=>{i.set(y,nM(n.subTree))},n.subTree.suspense):i.set(y,nM(n.subTree)))};return nz(_),nV(_),nH(()=>{i.forEach(e=>{let{subTree:t,suspense:r}=n,i=nM(t);if(e.type===i.type&&e.key===i.key){nB(i);let e=i.component.da;e&&rI(e,r);return}p(e)})}),()=>{if(y=null,!t.default)return s=null;let n=t.default(),r=n[0];if(n.length>1)return s=null,n;if(!is(r)||!(4&r.shapeFlag)&&!(128&r.shapeFlag))return s=null,r;let l=nM(r);if(l.type===r3)return s=null,l;let u=l.type,c=iB(nC(l)?l.type.__asyncResolved||{}:u),{include:d,exclude:f,max:h}=e;if(d&&(!c||!nR(d,c))||f&&c&&nR(f,c))return l.shapeFlag&=-257,s=l,r;let p=null==l.key?u:l.key,m=i.get(p);return l.el&&(l=ih(l),128&r.shapeFlag&&(r.ssContent=l)),y=p,m?(l.el=m.el,l.component=m.component,l.transition&&ng(l,l.transition),l.shapeFlag|=512,a.delete(p),a.add(p)):(a.add(p),h&&a.size>parseInt(h,10)&&g(a.values().next().value)),l.shapeFlag|=256,s=l,rY(r.type)?r:l}}};function nR(e,t){return P(e)?e.some(e=>nR(e,t)):z(e)?e.split(",").includes(t):!!F(e)&&(e.lastIndex=0,e.test(t))}function nU(e,t){nP(e,"a",t)}function nL(e,t){nP(e,"da",t)}function nP(e,t,n=ik){let r=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()});if(nN(t,r,n),n){let e=n.parent;for(;e&&e.parent;)nI(e.parent.vnode)&&function(e,t,n,r){let i=nN(t,e,r,!0);nW(()=>{R(r[t],i)},n)}(r,t,n,e),e=e.parent}}function nB(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function nM(e){return 128&e.shapeFlag?e.ssContent:e}function nN(e,t,n=ik,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||(t.__weh=(...r)=>{eU();let i=iE(n),a=tB(t,n,e,r);return i(),eL(),a});return r?i.unshift(a):i.push(a),a}}let nF=e=>(t,n=ik)=>{iO&&"sp"!==e||nN(e,(...e)=>t(...e),n)},nj=nF("bm"),nz=nF("m"),nG=nF("bu"),nV=nF("u"),nH=nF("bum"),nW=nF("um"),nq=nF("sp"),nK=nF("rtg"),nJ=nF("rtc");function nZ(e,t=ik){nN("ec",e,t)}let n$="components";function nY(e,t){return n0(n$,e,!0,t)||e}let nQ=Symbol.for("v-ndc");function nX(e){return z(e)?n0(n$,e,!1)||e:e||nQ}function n0(e,t,n=!0,r=!1){let i=tX||ik;if(i){let n=i.type;if(e===n$){let e=iB(n,!1);if(e&&(e===t||e===X(t)||e===en(X(t))))return n}let a=n1(i[e]||n[e],t)||n1(i.appContext[e],t);return!a&&r?n:a}}function n1(e,t){return e&&(e[t]||e[X(t)]||e[en(X(t))])}function n2(e,t,n,r){let i,a=n&&n[r],s=P(e);if(s||z(e)){let n=s&&tp(e),r=!1;n&&(r=!tm(e),e=eq(e)),i=Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=t(r?t_(e[n]):e[n],n,void 0,a&&a[n])}else if("number"==typeof e){i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}else if(V(e))if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,s=n.length;r<s;r++){let s=n[r];i[r]=t(e[s],s,r,a&&a[r])}}else i=[];return n&&(n[r]=i),i}let n5=e=>e?iA(e)?iU(e):n5(e.parent):null,n3=D(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>n5(e.parent),$root:e=>n5(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>rn(e),$forceUpdate:e=>e.f||(e.f=()=>{tq(e.update)}),$nextTick:e=>e.n||(e.n=tW.bind(e.proxy)),$watch:e=>rj.bind(e)}),n6=(e,t)=>e!==E&&!e.__isScriptSetup&&L(e,t),n4={get({_:e},t){let n,r,i;if("__v_skip"===t)return!0;let{ctx:a,setupState:s,data:l,props:u,accessCache:c,type:d,appContext:f}=e;if("$"!==t[0]){let r=c[t];if(void 0!==r)switch(r){case 1:return s[t];case 2:return l[t];case 4:return a[t];case 3:return u[t]}else{if(n6(s,t))return c[t]=1,s[t];if(l!==E&&L(l,t))return c[t]=2,l[t];if((n=e.propsOptions[0])&&L(n,t))return c[t]=3,u[t];if(a!==E&&L(a,t))return c[t]=4,a[t];re&&(c[t]=0)}}let h=n3[t];return h?("$attrs"===t&&eV(e.attrs,"get",""),h(e)):(r=d.__cssModules)&&(r=r[t])?r:a!==E&&L(a,t)?(c[t]=4,a[t]):L(i=f.config.globalProperties,t)?i[t]:void 0},set({_:e},t,n){let{data:r,setupState:i,ctx:a}=e;return n6(i,t)?(i[t]=n,!0):r!==E&&L(r,t)?(r[t]=n,!0):!L(e.props,t)&&!("$"===t[0]&&t.slice(1)in e)&&(a[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,propsOptions:a}},s){let l;return!!n[s]||e!==E&&L(e,s)||n6(t,s)||(l=a[0])&&L(l,s)||L(r,s)||L(n3,s)||L(i.config.globalProperties,s)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:L(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function n8(){return function(){let e=iS();return e.setupContext||(e.setupContext=iR(e))}().slots}function n9(e){return P(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}function n7(e,t){return e&&t?P(e)&&P(t)?e.concat(t):D({},n9(e),n9(t)):e||t}let re=!0;function rt(e,t,n){tB(P(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function rn(e){let t,n=e.type,{mixins:r,extends:i}=n,{mixins:a,optionsCache:s,config:{optionMergeStrategies:l}}=e.appContext,u=s.get(n);return u?t=u:a.length||r||i?(t={},a.length&&a.forEach(e=>rr(t,e,l,!0)),rr(t,n,l)):t=n,V(n)&&s.set(n,t),t}function rr(e,t,n,r=!1){let{mixins:i,extends:a}=t;for(let s in a&&rr(e,a,n,!0),i&&i.forEach(t=>rr(e,t,n,!0)),t)if(r&&"expose"===s);else{let r=ri[s]||n&&n[s];e[s]=r?r(e[s],t[s]):t[s]}return e}let ri={data:ra,props:ru,emits:ru,methods:rl,computed:rl,beforeCreate:ro,created:ro,beforeMount:ro,mounted:ro,beforeUpdate:ro,updated:ro,beforeDestroy:ro,beforeUnmount:ro,destroyed:ro,unmounted:ro,activated:ro,deactivated:ro,errorCaptured:ro,serverPrefetch:ro,components:rl,directives:rl,watch:function(e,t){if(!e)return t;if(!t)return e;let n=D(Object.create(null),e);for(let r in t)n[r]=ro(e[r],t[r]);return n},provide:ra,inject:function(e,t){return rl(rs(e),rs(t))}};function ra(e,t){return t?e?function(){return D(j(e)?e.call(this,this):e,j(t)?t.call(this,this):t)}:t:e}function rs(e){if(P(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function ro(e,t){return e?[...new Set([].concat(e,t))]:t}function rl(e,t){return e?D(Object.create(null),e,t):t}function ru(e,t){return e?P(e)&&P(t)?[...new Set([...e,...t])]:D(Object.create(null),n9(e),n9(null!=t?t:{})):t}function rc(){return{app:null,config:{isNativeTag:O,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let rd=0,rf=null;function rh(e,t){if(ik){let n=ik.provides,r=ik.parent&&ik.parent.provides;r===n&&(n=ik.provides=Object.create(r)),n[e]=t}}function rp(e,t,n=!1){let r=ik||tX;if(r||rf){let i=rf?rf._context.provides:r?null==r.parent?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&j(t)?t.call(r&&r.proxy):t}}let rv={},rm=()=>Object.create(rv),rg=e=>Object.getPrototypeOf(e)===rv;function ry(e,t,n,r){let i,[a,s]=e.propsOptions,l=!1;if(t)for(let u in t){let c;if($(u))continue;let d=t[u];a&&L(a,c=X(u))?s&&s.includes(c)?(i||(i={}))[c]=d:n[c]=d:rW(e.emitsOptions,u)||u in r&&d===r[u]||(r[u]=d,l=!0)}if(s){let t=ty(n),r=i||E;for(let i=0;i<s.length;i++){let l=s[i];n[l]=r_(a,t,l,r[l],e,!L(r,l))}}return l}function r_(e,t,n,r,i,a){let s=e[n];if(null!=s){let e=L(s,"default");if(e&&void 0===r){let e=s.default;if(s.type!==Function&&!s.skipFactory&&j(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let s=iE(i);r=a[n]=e.call(null,t),s()}}else r=e;i.ce&&i.ce._setProp(n,r)}s[0]&&(a&&!e?r=!1:s[1]&&(""===r||r===et(n))&&(r=!0))}return r}let rb=new WeakMap;function rw(e){return!("$"===e[0]||$(e))}let rx=e=>"_"===e[0]||"$stable"===e,rk=e=>P(e)?e.map(ig):[ig(e)],rS=(e,t,n)=>{if(t._n)return t;let r=t2((...e)=>rk(t(...e)),n);return r._c=!1,r},rE=(e,t,n)=>{let r=e._ctx;for(let n in e){if(rx(n))continue;let i=e[n];if(j(i))t[n]=rS(n,i,r);else if(null!=i){let e=rk(i);t[n]=()=>e}}},rT=(e,t)=>{let n=rk(t);e.slots.default=()=>n},rA=(e,t,n)=>{for(let r in t)(n||"_"!==r)&&(e[r]=t[r])},rO=(e,t,n)=>{let r=e.slots=rm();if(32&e.vnode.shapeFlag){let e=t._;e?(rA(r,t,n),n&&es(r,"_",e,!0)):rE(t,r)}else t&&rT(e,t)},rC=(e,t,n)=>{let{vnode:r,slots:i}=e,a=!0,s=E;if(32&r.shapeFlag){let e=t._;e?n&&1===e?a=!1:rA(i,t,n):(a=!t.$stable,rE(t,i)),s=t}else t&&(rT(e,t),s={default:1});if(a)for(let e in i)rx(e)||null!=s[e]||delete i[e]},rI=r0;function rD({type:e,props:t},n){return"svg"===n&&"foreignObject"===e||"mathml"===n&&"annotation-xml"===e&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function rR({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function rU(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function rL(e,t,n=!1){let r=e.children,i=t.children;if(P(r)&&P(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];1&a.shapeFlag&&!a.dynamicChildren&&((a.patchFlag<=0||32===a.patchFlag)&&((a=i[e]=iy(i[e])).el=t.el),n||-2===a.patchFlag||rL(t,a)),a.type===r5&&(a.el=t.el)}}function rP(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}let rB=Symbol.for("v-scx"),rM=()=>rp(rB);function rN(e,t){return rF(e,null,t)}function rF(e,n,r=E){let i,{immediate:a,deep:s,flush:l,once:u}=r,c=D({},r),d=n&&a||!n&&"post"!==l;if(iO){if("sync"===l){let e=rM();i=e.__watcherHandles||(e.__watcherHandles=[])}else if(!d){let e=()=>{};return e.stop=A,e.resume=A,e.pause=A,e}}let f=ik;c.call=(e,t,n)=>tB(e,f,t,n);let h=!1;"post"===l?c.scheduler=e=>{rI(e,f&&f.suspense)}:"sync"!==l&&(h=!0,c.scheduler=(e,t)=>{t?e():tq(e)}),c.augmentJob=e=>{n&&(e.flags|=4),h&&(e.flags|=2,f&&(e.id=f.uid,e.i=f))};let p=function(e,n,r=E){let i,a,s,l,{immediate:u,deep:c,once:d,scheduler:f,augmentJob:h,call:p}=r,m=e=>c?e:tm(e)||!1===c||0===c?tU(e,1):tU(e),g=!1,y=!1;if(tw(e)?(a=()=>e.value,g=tm(e)):tp(e)?(a=()=>m(e),g=!0):P(e)?(y=!0,g=e.some(e=>tp(e)||tm(e)),a=()=>e.map(e=>tw(e)?e.value:tp(e)?m(e):j(e)?p?p(e,2):e():void 0)):a=j(e)?n?p?()=>p(e,2):e:()=>{if(s){eU();try{s()}finally{eL()}}let t=x;x=i;try{return p?p(e,3,[l]):e(l)}finally{x=t}}:A,n&&c){let e=a,t=!0===c?1/0:c;a=()=>tU(e(),t)}let _=t,b=()=>{i.stop(),_&&_.active&&R(_.effects,i)};if(d&&n){let e=n;n=(...t)=>{e(...t),b()}}let w=y?Array(e.length).fill(tD):tD,k=e=>{if(1&i.flags&&(i.dirty||e))if(n){let e=i.run();if(c||g||(y?e.some((e,t)=>ei(e,w[t])):ei(e,w))){s&&s();let t=x;x=i;try{let t=[e,w===tD?void 0:y&&w[0]===tD?[]:w,l];p?p(n,3,t):n(...t),w=e}finally{x=t}}}else i.run()};return h&&h(k),(i=new ex(a)).scheduler=f?()=>f(k,!1):k,l=e=>(function(e,t=!1,n=x){if(n){let t=tR.get(n);t||tR.set(n,t=[]),t.push(e)}})(e,!1,i),s=i.onStop=()=>{let e=tR.get(i);if(e){if(p)p(e,4);else for(let t of e)t();tR.delete(i)}},n?u?k(!0):w=i.run():f?f(k.bind(null,!0),!0):i.run(),b.pause=i.pause.bind(i),b.resume=i.resume.bind(i),b.stop=b,b}(e,n,c);return iO&&(i?i.push(p):d&&p()),p}function rj(e,t,n){let r,i=this.proxy,a=z(e)?e.includes(".")?rz(i,e):()=>i[e]:e.bind(i,i);j(t)?r=t:(r=t.handler,n=t);let s=iE(this),l=rF(a,r.bind(i),n);return s(),l}function rz(e,t){let n=t.split(".");return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}function rG(e,t,n=E){let r=iS(),i=X(t),a=et(t),s=rV(e,i),l=new tO((s,l)=>{let u,c,d=E;return rF(()=>{let t=e[i];ei(u,t)&&(u=t,l())},null,{flush:"sync"}),{get:()=>(s(),n.get?n.get(u):u),set(e){let s=n.set?n.set(e):e;if(!ei(s,u)&&!(d!==E&&ei(e,d)))return;let f=r.vnode.props;f&&(t in f||i in f||a in f)&&(`onUpdate:${t}`in f||`onUpdate:${i}`in f||`onUpdate:${a}`in f)||(u=e,l()),r.emit(`update:${t}`,s),ei(e,s)&&ei(e,d)&&!ei(s,c)&&l(),d=e,c=s}}});return l[Symbol.iterator]=()=>{let e=0;return{next:()=>e<2?{value:e++?s||E:l,done:!1}:{done:!0}}},l}let rV=(e,t)=>"modelValue"===t||"model-value"===t?e.modelModifiers:e[`${t}Modifiers`]||e[`${X(t)}Modifiers`]||e[`${et(t)}Modifiers`];function rH(e,t,...n){let r;if(e.isUnmounted)return;let i=e.vnode.props||E,a=n,s=t.startsWith("update:"),l=s&&rV(i,t.slice(7));l&&(l.trim&&(a=n.map(e=>z(e)?e.trim():e)),l.number&&(a=n.map(eo)));let u=i[r=er(t)]||i[r=er(X(t))];!u&&s&&(u=i[r=er(et(t))]),u&&tB(u,e,6,a);let c=i[r+"Once"];if(c){if(e.emitted){if(e.emitted[r])return}else e.emitted={};e.emitted[r]=!0,tB(c,e,6,a)}}function rW(e,t){return!!e&&!!C(t)&&(L(e,(t=t.slice(2).replace(/Once$/,""))[0].toLowerCase()+t.slice(1))||L(e,et(t))||L(e,t))}function rq(e){let t,n,{type:r,vnode:i,proxy:a,withProxy:s,propsOptions:[l],slots:u,attrs:c,emit:d,render:f,renderCache:h,props:p,data:m,setupState:g,ctx:y,inheritAttrs:_}=e,b=t1(e);try{if(4&i.shapeFlag){let e=s||a;t=ig(f.call(e,e,h,p,g,m,y)),n=c}else t=ig(r.length>1?r(p,{attrs:c,slots:u,emit:d}):r(p,null)),n=r.props?c:rK(c)}catch(n){r4.length=0,tM(n,e,1),t=id(r3)}let w=t;if(n&&!1!==_){let e=Object.keys(n),{shapeFlag:t}=w;e.length&&7&t&&(l&&e.some(I)&&(n=rJ(n,l)),w=ih(w,n,!1,!0))}return i.dirs&&((w=ih(w,null,!1,!0)).dirs=w.dirs?w.dirs.concat(i.dirs):i.dirs),i.transition&&ng(w,i.transition),t=w,t1(b),t}let rK=e=>{let t;for(let n in e)("class"===n||"style"===n||C(n))&&((t||(t={}))[n]=e[n]);return t},rJ=(e,t)=>{let n={};for(let r in e)I(r)&&r.slice(9)in t||(n[r]=e[r]);return n};function rZ(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(t[a]!==e[a]&&!rW(n,a))return!0}return!1}function r$({vnode:e,parent:t},n){for(;t;){let r=t.subTree;if(r.suspense&&r.suspense.activeBranch===e&&(r.el=e.el),r===e)(e=t.vnode).el=n,t=t.parent;else break}}let rY=e=>e.__isSuspense,rQ=0;function rX(e,t){let n=e.props&&e.props[t];isFunction(n)&&n()}function r0(e,t){t&&t.pendingBranch?P(e)?t.effects.push(...e):t.effects.push(e):tJ(e)}function r1(e,t){e.activeBranch=t;let{vnode:n,parentComponent:r}=e,i=t.el;for(;!i&&t.component;)i=(t=t.component.subTree).el;n.el=i,r&&r.subTree===n&&(r.vnode.el=i,r$(r,i))}let r2=Symbol.for("v-fgt"),r5=Symbol.for("v-txt"),r3=Symbol.for("v-cmt"),r6=Symbol.for("v-stc"),r4=[],r8=null;function r9(e=!1){r4.push(r8=e?null:[])}function r7(){r4.pop(),r8=r4[r4.length-1]||null}let ie=1;function it(e,t=!1){ie+=e,e<0&&r8&&t&&(r8.hasOnce=!0)}function ir(e){return e.dynamicChildren=ie>0?r8||T:null,r7(),ie>0&&r8&&r8.push(e),e}function ii(e,t,n,r,i,a){return ir(ic(e,t,n,r,i,a,!0))}function ia(e,t,n,r,i){return ir(id(e,t,n,r,i,!0))}function is(e){return!!e&&!0===e.__v_isVNode}function io(e,t){return e.type===t.type&&e.key===t.key}let il=({key:e})=>null!=e?e:null,iu=({ref:e,ref_key:t,ref_for:n})=>("number"==typeof e&&(e=""+e),null!=e?z(e)||tw(e)||j(e)?{i:tX,r:e,k:t,f:!!n}:e:null);function ic(e,t=null,n=null,r=0,i=null,a=+(e!==r2),s=!1,l=!1){let u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&il(t),ref:t&&iu(t),scopeId:t0,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:tX};return l?(i_(u,n),128&a&&e.normalize(u)):n&&(u.shapeFlag|=z(n)?8:16),ie>0&&!s&&r8&&(u.patchFlag>0||6&a)&&32!==u.patchFlag&&r8.push(u),u}let id=function(e,t=null,n=null,r=0,i=null,a=!1){if(e&&e!==nQ||(e=r3),is(e)){let r=ih(e,t,!0);return n&&i_(r,n),ie>0&&!a&&r8&&(6&r.shapeFlag?r8[r8.indexOf(e)]=r:r8.push(r)),r.patchFlag=-2,r}if(iN(e)&&(e=e.__vccOpts),t){var s;let{class:e,style:n}=t=(s=t)?tg(s)||rg(s)?D({},s):s:null;e&&!z(e)&&(t.class=ep(e)),V(n)&&(tg(n)&&!P(n)&&(n=D({},n)),t.style=ec(n))}let l=z(e)?1:rY(e)?128:t4(e)?64:V(e)?4:2*!!j(e);return ic(e,t,n,r,i,l,a,!0)};function ih(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:s,children:l,transition:u}=e,c=t?function(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if("class"===e)t.class!==r.class&&(t.class=ep([t.class,r.class]));else if("style"===e)t.style=ec([t.style,r.style]);else if(C(e)){let n=t[e],i=r[e];i&&n!==i&&!(P(n)&&n.includes(i))&&(t[e]=n?[].concat(n,i):i)}else""!==e&&(t[e]=r[e])}return t}(i||{},t):i,d={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&il(c),ref:t&&t.ref?n&&a?P(a)?a.concat(iu(t)):[a,iu(t)]:iu(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==r2?-1===s?16:16|s:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&ih(e.ssContent),ssFallback:e.ssFallback&&ih(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return u&&r&&ng(d,u.clone(d)),d}function ip(e){let t=ih(e);return isArray(e.children)&&(t.children=e.children.map(ip)),t}function iv(e=" ",t=0){return id(r5,null,e,t)}function im(e="",t=!1){return t?(r9(),ia(r3,null,e)):id(r3,null,e)}function ig(e){return null==e||"boolean"==typeof e?id(r3):P(e)?id(r2,null,e.slice()):is(e)?iy(e):id(r5,null,String(e))}function iy(e){return null===e.el&&-1!==e.patchFlag||e.memo?e:ih(e)}function i_(e,t){let n=0,{shapeFlag:r}=e;if(null==t)t=null;else if(P(t))n=16;else if("object"==typeof t)if(65&r){let n=t.default;n&&(n._c&&(n._d=!1),i_(e,n()),n._c&&(n._d=!0));return}else{n=32;let r=t._;r||rg(t)?3===r&&tX&&(1===tX.slots._?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=tX}else j(t)?(t={default:t,_ctx:tX},n=32):(t=String(t),64&r?(n=16,t=[iv(t)]):n=8);e.children=t,e.shapeFlag|=n}function ib(e,t,n,r=null){tB(e,t,7,[n,r])}let iw=rc(),ix=0,ik=null,iS=()=>ik||tX;{let e=eu(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};c=t("__VUE_INSTANCE_SETTERS__",e=>ik=e),d=t("__VUE_SSR_SETTERS__",e=>iO=e)}let iE=e=>{let t=ik;return c(e),e.scope.on(),()=>{e.scope.off(),c(t)}},iT=()=>{ik&&ik.scope.off(),c(null)};function iA(e){return 4&e.vnode.shapeFlag}let iO=!1;function iC(e,t,n){j(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:V(t)&&(e.setupState=tA(t)),iI(e,n)}function iI(e,t,n){let r=e.type;if(!e.render){if(!t&&f&&!r.render){let t=r.template||rn(e).template;if(t){let{isCustomElement:n,compilerOptions:i}=e.appContext.config,{delimiters:a,compilerOptions:s}=r;r.render=f(t,D(D({isCustomElement:n,delimiters:a},i),s))}}e.render=r.render||A,h&&h(e)}{let t=iE(e);eU();try{!function(e){let t=rn(e),n=e.proxy,r=e.ctx;re=!1,t.beforeCreate&&rt(t.beforeCreate,e,"bc");let{data:i,computed:a,methods:s,watch:l,provide:u,inject:c,created:d,beforeMount:f,mounted:h,beforeUpdate:p,updated:m,activated:g,deactivated:y,beforeDestroy:_,beforeUnmount:b,destroyed:w,unmounted:x,render:k,renderTracked:S,renderTriggered:E,errorCaptured:T,serverPrefetch:O,expose:C,inheritAttrs:I,components:D,directives:R,filters:U}=t;if(c&&function(e,t,n=A){for(let n in P(e)&&(e=rs(e)),e){let r,i=e[n];tw(r=V(i)?"default"in i?rp(i.from||n,i.default,!0):rp(i.from||n):rp(i))?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>r.value,set:e=>r.value=e}):t[n]=r}}(c,r,null),s)for(let e in s){let t=s[e];j(t)&&(r[e]=t.bind(n))}if(i){let t=i.call(n,n);V(t)&&(e.data=tc(t))}if(re=!0,a)for(let e in a){let t=a[e],i=j(t)?t.bind(n,n):j(t.get)?t.get.bind(n,n):A,s=iF({get:i,set:!j(t)&&j(t.set)?t.set.bind(n):A});Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>s.value,set:e=>s.value=e})}if(l)for(let e in l)!function e(t,n,r,i){let a=i.includes(".")?rz(r,i):()=>r[i];if(z(t)){let e=n[t];var s,l,u,c,d,f=void 0;j(e)&&(c=a,d=e,rF(c,d,void 0))}else if(j(t)){var h,p,m=void 0;h=a,p=t.bind(r),rF(h,p,void 0)}else if(V(t))if(P(t))t.forEach(t=>e(t,n,r,i));else{let e=j(t.handler)?t.handler.bind(r):n[t.handler];j(e)&&(s=a,l=e,u=t,rF(s,l,u))}}(l[e],r,n,e);if(u){let e=j(u)?u.call(n):u;Reflect.ownKeys(e).forEach(t=>{rh(t,e[t])})}function L(e,t){P(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(d&&rt(d,e,"c"),L(nj,f),L(nz,h),L(nG,p),L(nV,m),L(nU,g),L(nL,y),L(nZ,T),L(nJ,S),L(nK,E),L(nH,b),L(nW,x),L(nq,O),P(C))if(C.length){let t=e.exposed||(e.exposed={});C.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t})})}else e.exposed||(e.exposed={});k&&e.render===A&&(e.render=k),null!=I&&(e.inheritAttrs=I),D&&(e.components=D),R&&(e.directives=R),O&&n_(e)}(e)}finally{eL(),t()}}}let iD={get:(e,t)=>(eV(e,"get",""),e[t])};function iR(e){return{attrs:new Proxy(e.attrs,iD),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function iU(e){var t;return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(tA((!L(t=e.exposed,"__v_skip")&&Object.isExtensible(t)&&es(t,"__v_skip",!0),t)),{get:(t,n)=>n in t?t[n]:n in n3?n3[n](e):void 0,has:(e,t)=>t in e||t in n3})):e.proxy}let iL=/(?:^|[-_])(\w)/g,iP=e=>e.replace(iL,e=>e.toUpperCase()).replace(/[-_]/g,"");function iB(e,t=!0){return j(e)?e.displayName||e.name:e.name||t&&e.__name}function iM(e,t,n=!1){let r=iB(t);if(!r&&t.__file){let e=t.__file.match(/([^/\\]+)\.\w+$/);e&&(r=e[1])}if(!r&&e&&e.parent){let n=e=>{for(let n in e)if(e[n]===t)return n};r=n(e.components||e.parent.type.components)||n(e.appContext.components)}return r?iP(r):n?"App":"Anonymous"}function iN(e){return j(e)&&"__vccOpts"in e}let iF=(e,t)=>(function(e,t,n=!1){let r,i;return j(e)?r=e:(r=e.get,i=e.set),new tI(r,i,n)})(e,0,iO);function ij(e,t,n){let r=arguments.length;return 2!==r?(r>3?n=Array.prototype.slice.call(arguments,2):3===r&&is(n)&&(n=[n]),id(e,t,n)):!V(t)||P(t)?id(e,null,t):is(t)?id(e,null,[t]):id(e,t)}let iz="3.5.13",iG="undefined"!=typeof window&&window.trustedTypes;if(iG)try{k=iG.createPolicy("vue",{createHTML:e=>e})}catch(e){}let iV=k?e=>k.createHTML(e):e=>e,iH="undefined"!=typeof document?document:null,iW=iH&&iH.createElement("template"),iq="transition",iK="animation",iJ=Symbol("_vtc"),iZ={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},i$=D({},nu,iZ),iY=(e=>(e.displayName="Transition",e.props=i$,e))((e,{slots:t})=>ij(nf,function(e){let t={};for(let n in e)n in iZ||(t[n]=e[n]);if(!1===e.css)return t;let{name:n="v",type:r,duration:i,enterFromClass:a=`${n}-enter-from`,enterActiveClass:s=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:u=a,appearActiveClass:c=s,appearToClass:d=l,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:h=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=e,m=function(e){if(null==e)return null;{if(V(e))return[function(e){return el(e)}(e.enter),function(e){return el(e)}(e.leave)];let t=function(e){return el(e)}(e);return[t,t]}}(i),g=m&&m[0],y=m&&m[1],{onBeforeEnter:_,onEnter:b,onEnterCancelled:w,onLeave:x,onLeaveCancelled:k,onBeforeAppear:S=_,onAppear:E=b,onAppearCancelled:T=w}=t,A=(e,t,n,r)=>{e._enterCancelled=r,i2(e,t?d:l),i2(e,t?c:s),n&&n()},O=(e,t)=>{e._isLeaving=!1,i2(e,f),i2(e,p),i2(e,h),t&&t()},C=e=>(t,n)=>{let i=e?E:b,s=()=>A(t,e,n);iQ(i,[t,s]),i5(()=>{i2(t,e?u:a),i1(t,e?d:l),iX(i)||i6(t,r,g,s)})};return D(t,{onBeforeEnter(e){iQ(_,[e]),i1(e,a),i1(e,s)},onBeforeAppear(e){iQ(S,[e]),i1(e,u),i1(e,c)},onEnter:C(!1),onAppear:C(!0),onLeave(e,t){e._isLeaving=!0;let n=()=>O(e,t);i1(e,f),e._enterCancelled?(i1(e,h),i9()):(i9(),i1(e,h)),i5(()=>{e._isLeaving&&(i2(e,f),i1(e,p),iX(x)||i6(e,r,y,n))}),iQ(x,[e,n])},onEnterCancelled(e){A(e,!1,void 0,!0),iQ(w,[e])},onAppearCancelled(e){A(e,!0,void 0,!0),iQ(T,[e])},onLeaveCancelled(e){O(e),iQ(k,[e])}})}(e),t)),iQ=(e,t=[])=>{P(e)?e.forEach(e=>e(...t)):e&&e(...t)},iX=e=>!!e&&(P(e)?e.some(e=>e.length>1):e.length>1);function i0(e){return el(e)}function i1(e,t){t.split(/\s+/).forEach(t=>t&&e.classList.add(t)),(e[iJ]||(e[iJ]=new Set)).add(t)}function i2(e,t){t.split(/\s+/).forEach(t=>t&&e.classList.remove(t));let n=e[iJ];n&&(n.delete(t),n.size||(e[iJ]=void 0))}function i5(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let i3=0;function i6(e,t,n,r){let i=e._endId=++i3,a=()=>{i===e._endId&&r()};if(null!=n)return setTimeout(a,n);let{type:s,timeout:l,propCount:u}=function(e,t){let n=window.getComputedStyle(e),r=e=>(n[e]||"").split(", "),i=r(`${iq}Delay`),a=r(`${iq}Duration`),s=i4(i,a),l=r(`${iK}Delay`),u=r(`${iK}Duration`),c=i4(l,u),d=null,f=0,h=0;t===iq?s>0&&(d=iq,f=s,h=a.length):t===iK?c>0&&(d=iK,f=c,h=u.length):h=(d=(f=Math.max(s,c))>0?s>c?iq:iK:null)?d===iq?a.length:u.length:0;let p=d===iq&&/\b(transform|all)(,|$)/.test(r(`${iq}Property`).toString());return{type:d,timeout:f,propCount:h,hasTransform:p}}(e,t);if(!s)return r();let c=s+"end",d=0,f=()=>{e.removeEventListener(c,h),a()},h=t=>{t.target===e&&++d>=u&&f()};setTimeout(()=>{d<u&&f()},l+1),e.addEventListener(c,h)}function i4(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((t,n)=>i8(t)+i8(e[n])))}function i8(e){return"auto"===e?0:1e3*Number(e.slice(0,-1).replace(",","."))}function i9(){return document.body.offsetHeight}let i7=Symbol("_vod"),ae=Symbol("_vsh"),at={beforeMount(e,{value:t},{transition:n}){e[i7]="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):an(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),an(e,!0),r.enter(e)):r.leave(e,()=>{an(e,!1)}):an(e,t))},beforeUnmount(e,{value:t}){an(e,t)}};function an(e,t){e.style.display=t?e[i7]:"none",e[ae]=!t}let ar=Symbol(""),ai=/(^|;)\s*display\s*:/,aa=/\s*!important$/;function as(e,t,n){if(P(n))n.forEach(n=>as(e,t,n));else if(null==n&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{let r=function(e,t){let n=al[t];if(n)return n;let r=X(t);if("filter"!==r&&r in e)return al[t]=r;r=en(r);for(let n=0;n<ao.length;n++){let i=ao[n]+r;if(i in e)return al[t]=i}return t}(e,t);aa.test(n)?e.setProperty(et(r),n.replace(aa,""),"important"):e[r]=n}}let ao=["Webkit","Moz","ms"],al={},au="http://www.w3.org/1999/xlink";function ac(e,t,n,r,i,a=ev(t)){if(r&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(au,t.slice(6,t.length)):e.setAttributeNS(au,t,n);else null==n||a&&!(n||""===n)?e.removeAttribute(t):e.setAttribute(t,a?"":G(n)?String(n):n)}function ad(e,t,n,r,i){if("innerHTML"===t||"textContent"===t){null!=n&&(e[t]="innerHTML"===t?iV(n):n);return}let a=e.tagName;if("value"===t&&"PROGRESS"!==a&&!a.includes("-")){let r="OPTION"===a?e.getAttribute("value")||"":e.value,i=null==n?"checkbox"===e.type?"on":"":String(n);r===i&&"_value"in e||(e.value=i),null==n&&e.removeAttribute(t),e._value=n;return}let s=!1;if(""===n||null==n){let r=typeof e[t];if("boolean"===r){var l;n=!!(l=n)||""===l}else null==n&&"string"===r?(n="",s=!0):"number"===r&&(n=0,s=!0)}try{e[t]=n}catch(e){}s&&e.removeAttribute(i||t)}function af(e,t,n,r){e.addEventListener(t,n,r)}let ah=Symbol("_vei"),ap=/(?:Once|Passive|Capture)$/,av=0,am=Promise.resolve(),ag=()=>av||(am.then(()=>av=0),av=Date.now()),ay=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)>96&&123>e.charCodeAt(2),a_={},ab="undefined"!=typeof HTMLElement?HTMLElement:class{};class aw extends ab{constructor(e,t={},n=aP){super(),this._def=e,this._props=t,this._createApp=n,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&n!==aP?this._root=this.shadowRoot:!1!==e.shadowRoot?(this.attachShadow({mode:"open"}),this._root=this.shadowRoot):this._root=this,this._def.__asyncLoader||this._resolveProps(this._def)}connectedCallback(){if(!this.isConnected)return;this.shadowRoot||this._parseSlots(),this._connected=!0;let e=this;for(;e=e&&(e.parentNode||e.host);)if(e instanceof aw){this._parent=e;break}this._instance||(this._resolved?(this._setParent(),this._update()):e&&e._pendingResolve?this._pendingResolve=e._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(e=this._parent){e&&(this._instance.parent=e._instance,this._instance.provides=e._instance.provides)}disconnectedCallback(){this._connected=!1,tW(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null)})}_resolveDef(){if(this._pendingResolve)return;for(let e=0;e<this.attributes.length;e++)this._setAttr(this.attributes[e].name);this._ob=new MutationObserver(e=>{for(let t of e)this._setAttr(t.attributeName)}),this._ob.observe(this,{attributes:!0});let e=(e,t=!1)=>{let n;this._resolved=!0,this._pendingResolve=void 0;let{props:r,styles:i}=e;if(r&&!P(r))for(let e in r){let t=r[e];(t===Number||t&&t.type===Number)&&(e in this._props&&(this._props[e]=el(this._props[e])),(n||(n=Object.create(null)))[X(e)]=!0)}this._numberProps=n,t&&this._resolveProps(e),this.shadowRoot&&this._applyStyles(i),this._mount(e)},t=this._def.__asyncLoader;t?this._pendingResolve=t().then(t=>e(this._def=t,!0)):e(this._def)}_mount(e){this._app=this._createApp(e),e.configureApp&&e.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);let t=this._instance&&this._instance.exposed;if(t)for(let e in t)L(this,e)||Object.defineProperty(this,e,{get:()=>tE(t[e])})}_resolveProps(e){let{props:t}=e,n=P(t)?t:Object.keys(t||{});for(let e of Object.keys(this))"_"!==e[0]&&n.includes(e)&&this._setProp(e,this[e]);for(let e of n.map(X))Object.defineProperty(this,e,{get(){return this._getProp(e)},set(t){this._setProp(e,t,!0,!0)}})}_setAttr(e){if(e.startsWith("data-v-"))return;let t=this.hasAttribute(e),n=t?this.getAttribute(e):a_,r=X(e);t&&this._numberProps&&this._numberProps[r]&&(n=el(n)),this._setProp(r,n,!1,!0)}_getProp(e){return this._props[e]}_setProp(e,t,n=!0,r=!1){if(t!==this._props[e]&&(t===a_?delete this._props[e]:(this._props[e]=t,"key"===e&&this._app&&(this._app._ceVNode.key=t)),r&&this._instance&&this._update(),n)){let n=this._ob;n&&n.disconnect(),!0===t?this.setAttribute(et(e),""):"string"==typeof t||"number"==typeof t?this.setAttribute(et(e),t+""):t||this.removeAttribute(et(e)),n&&n.observe(this,{attributes:!0})}}_update(){aL(this._createVNode(),this._root)}_createVNode(){let e={};this.shadowRoot||(e.onVnodeMounted=e.onVnodeUpdated=this._renderSlots.bind(this));let t=id(this._def,D(e,this._props));return this._instance||(t.ce=e=>{this._instance=e,e.ce=this,e.isCE=!0;let t=(e,t)=>{this.dispatchEvent(new CustomEvent(e,J(t[0])?D({detail:t},t[0]):{detail:t}))};e.emit=(e,...n)=>{t(e,n),et(e)!==e&&t(et(e),n)},this._setParent()}),t}_applyStyles(e,t){if(!e)return;if(t){if(t===this._def||this._styleChildren.has(t))return;this._styleChildren.add(t)}let n=this._nonce;for(let t=e.length-1;t>=0;t--){let r=document.createElement("style");n&&r.setAttribute("nonce",n),r.textContent=e[t],this.shadowRoot.prepend(r)}}_parseSlots(){let e,t=this._slots={};for(;e=this.firstChild;){let n=1===e.nodeType&&e.getAttribute("slot")||"default";(t[n]||(t[n]=[])).push(e),this.removeChild(e)}}_renderSlots(){let e=(this._teleportTarget||this).querySelectorAll("slot"),t=this._instance.type.__scopeId;for(let n=0;n<e.length;n++){let r=e[n],i=r.getAttribute("name")||"default",a=this._slots[i],s=r.parentNode;if(a)for(let e of a){if(t&&1===e.nodeType){let n,r=t+"-s",i=document.createTreeWalker(e,1);for(e.setAttribute(r,"");n=i.nextNode();)n.setAttribute(r,"")}s.insertBefore(e,r)}else for(;r.firstChild;)s.insertBefore(r.firstChild,r);s.removeChild(r)}}_injectChildStyle(e){this._applyStyles(e.styles,e)}_removeChildStyle(e){}}Symbol("_moveCb"),Symbol("_enterCb");let ax=e=>{let t=e.props["onUpdate:modelValue"]||!1;return P(t)?e=>ea(t,e):t};function ak(e){e.target.composing=!0}function aS(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}let aE=Symbol("_assign"),aT={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e[aE]=ax(i);let a=r||i.props&&"number"===i.props.type;af(e,t?"change":"input",t=>{if(t.target.composing)return;let r=e.value;n&&(r=r.trim()),a&&(r=eo(r)),e[aE](r)}),n&&af(e,"change",()=>{e.value=e.value.trim()}),t||(af(e,"compositionstart",ak),af(e,"compositionend",aS),af(e,"change",aS))},mounted(e,{value:t}){e.value=null==t?"":t},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:a}},s){if(e[aE]=ax(s),e.composing)return;let l=(a||"number"===e.type)&&!/^0\d/.test(e.value)?eo(e.value):e.value,u=null==t?"":t;if(l!==u){if(document.activeElement===e&&"range"!==e.type&&(r&&t===n||i&&e.value.trim()===u))return;e.value=u}}},aA=["ctrl","shift","alt","meta"],aO={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&0!==e.button,middle:e=>"button"in e&&1!==e.button,right:e=>"button"in e&&2!==e.button,exact:(e,t)=>aA.some(n=>e[`${n}Key`]&&!t.includes(n))},aC=(e,t)=>{let n=e._withMods||(e._withMods={}),r=t.join(".");return n[r]||(n[r]=(n,...r)=>{for(let e=0;e<t.length;e++){let r=aO[t[e]];if(r&&r(n,t))return}return e(n,...r)})},aI={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},aD=(e,t)=>{let n=e._withKeys||(e._withKeys={}),r=t.join(".");return n[r]||(n[r]=n=>{if(!("key"in n))return;let r=et(n.key);if(t.some(e=>e===r||aI[e]===r))return e(n)})},aR=D({patchProp:(e,t,n,r,i,a)=>{let s="svg"===i;"class"===t?function(e,t,n){let r=e[iJ];r&&(t=(t?[t,...r]:[...r]).join(" ")),null==t?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}(e,r,s):"style"===t?function(e,t,n){let r=e.style,i=z(n),a=!1;if(n&&!i){if(t)if(z(t))for(let e of t.split(";")){let t=e.slice(0,e.indexOf(":")).trim();null==n[t]&&as(r,t,"")}else for(let e in t)null==n[e]&&as(r,e,"");for(let e in n)"display"===e&&(a=!0),as(r,e,n[e])}else if(i){if(t!==n){let e=r[ar];e&&(n+=";"+e),r.cssText=n,a=ai.test(n)}}else t&&e.removeAttribute("style");i7 in e&&(e[i7]=a?r.display:"",e[ae]&&(r.display="none"))}(e,n,r):C(t)?I(t)||function(e,t,n,r,i=null){let a=e[ah]||(e[ah]={}),s=a[t];if(r&&s)s.value=r;else{let[n,l]=function(e){let t;if(ap.test(e)){let n;for(t={};n=e.match(ap);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[":"===e[2]?e.slice(3):et(e.slice(2)),t]}(t);if(r)af(e,n,a[t]=function(e,t){let n=e=>{if(e._vts){if(e._vts<=n.attached)return}else e._vts=Date.now();tB(function(e,t){if(!P(t))return t;{let n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(e=>t=>!t._stopped&&e&&e(t))}}(e,n.value),t,5,[e])};return n.value=e,n.attached=ag(),n}(r,i),l);else s&&(e.removeEventListener(n,s,l),a[t]=void 0)}}(e,t,0,r,a):("."===t[0]?(t=t.slice(1),0):"^"===t[0]?(t=t.slice(1),1):!function(e,t,n,r){if(r)return!!("innerHTML"===t||"textContent"===t||t in e&&ay(t)&&j(n));if("spellcheck"===t||"draggable"===t||"translate"===t||"form"===t||"list"===t&&"INPUT"===e.tagName||"type"===t&&"TEXTAREA"===e.tagName)return!1;if("width"===t||"height"===t){let t=e.tagName;if("IMG"===t||"VIDEO"===t||"CANVAS"===t||"SOURCE"===t)return!1}return!(ay(t)&&z(n))&&t in e}(e,t,r,s))?e._isVueCE&&(/[A-Z]/.test(t)||!z(r))?ad(e,X(t),r,a,t):("true-value"===t?e._trueValue=r:"false-value"===t&&(e._falseValue=r),ac(e,t,r,s)):(ad(e,t,r),e.tagName.includes("-")||"value"!==t&&"checked"!==t&&"selected"!==t||ac(e,t,r,s,a,"value"!==t))}},{insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i="svg"===t?iH.createElementNS("http://www.w3.org/2000/svg",e):"mathml"===t?iH.createElementNS("http://www.w3.org/1998/Math/MathML",e):n?iH.createElement(e,{is:n}):iH.createElement(e);return"select"===e&&r&&null!=r.multiple&&i.setAttribute("multiple",r.multiple),i},createText:e=>iH.createTextNode(e),createComment:e=>iH.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>iH.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,i,a){let s=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==a&&(i=i.nextSibling););else{iW.innerHTML=iV("svg"===r?`<svg>${e}</svg>`:"mathml"===r?`<math>${e}</math>`:e);let i=iW.content;if("svg"===r||"mathml"===r){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[s?s.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}});function aU(){return p||(p=function(e,t){var n;let r,i;eu().__VUE__=!0;let{insert:a,remove:s,patchProp:l,createElement:u,createText:c,createComment:f,setText:h,setElementText:p,parentNode:m,nextSibling:g,setScopeId:y=A,insertStaticContent:_}=e,b=(e,t,n,r=null,i=null,a=null,s,l=null,u=!!t.dynamicChildren)=>{if(e===t)return;e&&!io(e,t)&&(r=eo(e),ee(e,i,a,!0),e=null),-2===t.patchFlag&&(u=!1,t.dynamicChildren=null);let{type:c,ref:d,shapeFlag:f}=t;switch(c){case r5:w(e,t,n,r);break;case r3:x(e,t,n,r);break;case r6:null==e&&k(t,n,r,s);break;case r2:F(e,t,n,r,i,a,s,l,u);break;default:1&f?C(e,t,n,r,i,a,s,l,u):6&f?z(e,t,n,r,i,a,s,l,u):(64&f||128&f)&&c.process(e,t,n,r,i,a,s,l,u,ed)}null!=d&&i&&nb(d,e&&e.ref,a,t||e,!t)},w=(e,t,n,r)=>{if(null==e)a(t.el=c(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&h(n,t.children)}},x=(e,t,n,r)=>{null==e?a(t.el=f(t.children||""),n,r):t.el=e.el},k=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=g(e),a(e,n,r),e=i;a(t,n,r)},O=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=g(e),s(e),e=n;s(t)},C=(e,t,n,r,i,a,s,l,u)=>{"svg"===t.type?s="svg":"math"===t.type&&(s="mathml"),null==e?I(t,n,r,i,a,s,l,u):B(e,t,i,a,s,l,u)},I=(e,t,n,r,i,s,c,d)=>{let f,h,{props:m,shapeFlag:g,transition:y,dirs:_}=e;if(f=e.el=u(e.type,s,m&&m.is,m),8&g?p(f,e.children):16&g&&U(e.children,f,null,r,i,rD(e,s),c,d),_&&t3(e,null,r,"created"),R(f,e,e.scopeId,c,r),m){for(let e in m)"value"===e||$(e)||l(f,e,null,m[e],s,r);"value"in m&&l(f,"value",null,m.value,s),(h=m.onVnodeBeforeMount)&&ib(h,r,e)}_&&t3(e,null,r,"beforeMount");let b=rU(i,y);b&&y.beforeEnter(f),a(f,t,n),((h=m&&m.onVnodeMounted)||b||_)&&rI(()=>{h&&ib(h,r,e),b&&y.enter(f),_&&t3(e,null,r,"mounted")},i)},R=(e,t,n,r,i)=>{if(n&&y(e,n),r)for(let t=0;t<r.length;t++)y(e,r[t]);if(i){let n=i.subTree;if(t===n||rY(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;R(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},U=(e,t,n,r,i,a,s,l,u=0)=>{for(let c=u;c<e.length;c++)b(null,e[c]=l?iy(e[c]):ig(e[c]),t,n,r,i,a,s,l)},B=(e,t,n,r,i,a,s)=>{let u,c=t.el=e.el,{patchFlag:d,dynamicChildren:f,dirs:h}=t;d|=16&e.patchFlag;let m=e.props||E,g=t.props||E;if(n&&rR(n,!1),(u=g.onVnodeBeforeUpdate)&&ib(u,n,t,e),h&&t3(t,e,n,"beforeUpdate"),n&&rR(n,!0),(m.innerHTML&&null==g.innerHTML||m.textContent&&null==g.textContent)&&p(c,""),f?M(e.dynamicChildren,f,c,n,r,rD(t,i),a):s||J(e,t,c,null,n,r,rD(t,i),a,!1),d>0){if(16&d)N(c,m,g,n,i);else if(2&d&&m.class!==g.class&&l(c,"class",null,g.class,i),4&d&&l(c,"style",m.style,g.style,i),8&d){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let r=e[t],a=m[r],s=g[r];(s!==a||"value"===r)&&l(c,r,a,s,i,n)}}1&d&&e.children!==t.children&&p(c,t.children)}else s||null!=f||N(c,m,g,n,i);((u=g.onVnodeUpdated)||h)&&rI(()=>{u&&ib(u,n,t,e),h&&t3(t,e,n,"updated")},r)},M=(e,t,n,r,i,a,s)=>{for(let l=0;l<t.length;l++){let u=e[l],c=t[l],d=u.el&&(u.type===r2||!io(u,c)||70&u.shapeFlag)?m(u.el):n;b(u,c,d,null,r,i,a,s,!0)}},N=(e,t,n,r,i)=>{if(t!==n){if(t!==E)for(let a in t)$(a)||a in n||l(e,a,t[a],null,i,r);for(let a in n){if($(a))continue;let s=n[a],u=t[a];s!==u&&"value"!==a&&l(e,a,u,s,i,r)}"value"in n&&l(e,"value",t.value,n.value,i)}},F=(e,t,n,r,i,s,l,u,d)=>{let f=t.el=e?e.el:c(""),h=t.anchor=e?e.anchor:c(""),{patchFlag:p,dynamicChildren:m,slotScopeIds:g}=t;(g&&(u=u?u.concat(g):g),null==e)?(a(f,n,r),a(h,n,r),U(t.children||[],n,h,i,s,l,u,d)):p>0&&64&p&&m&&e.dynamicChildren?(M(e.dynamicChildren,m,n,i,s,l,u),(null!=t.key||i&&t===i.subTree)&&rL(e,t,!0)):J(e,t,n,h,i,s,l,u,d)},z=(e,t,n,r,i,a,s,l,u)=>{t.slotScopeIds=l,null==e?512&t.shapeFlag?i.ctx.activate(t,n,r,s,u):G(t,n,r,i,a,s,u):W(e,t,u)},G=(e,t,n,r,i,a,s)=>{let l=e.component=function(e,t,n){let r=e.type,i=(t?t.appContext:e.appContext)||iw,a={uid:ix++,vnode:e,type:r,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new eb(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:function e(t,n,r=!1){let i=r?rb:n.propsCache,a=i.get(t);if(a)return a;let s=t.props,l={},u=[],c=!1;if(!j(t)){let i=t=>{c=!0;let[r,i]=e(t,n,!0);D(l,r),i&&u.push(...i)};!r&&n.mixins.length&&n.mixins.forEach(i),t.extends&&i(t.extends),t.mixins&&t.mixins.forEach(i)}if(!s&&!c)return V(t)&&i.set(t,T),T;if(P(s))for(let e=0;e<s.length;e++){let t=X(s[e]);rw(t)&&(l[t]=E)}else if(s)for(let e in s){let t=X(e);if(rw(t)){let n=s[e],r=l[t]=P(n)||j(n)?{type:n}:D({},n),i=r.type,a=!1,c=!0;if(P(i))for(let e=0;e<i.length;++e){let t=i[e],n=j(t)&&t.name;if("Boolean"===n){a=!0;break}"String"===n&&(c=!1)}else a=j(i)&&"Boolean"===i.name;r[0]=a,r[1]=c,(a||L(r,"default"))&&u.push(t)}}let d=[l,u];return V(t)&&i.set(t,d),d}(r,i),emitsOptions:function e(t,n,r=!1){let i=n.emitsCache,a=i.get(t);if(void 0!==a)return a;let s=t.emits,l={},u=!1;if(!j(t)){let i=t=>{let r=e(t,n,!0);r&&(u=!0,D(l,r))};!r&&n.mixins.length&&n.mixins.forEach(i),t.extends&&i(t.extends),t.mixins&&t.mixins.forEach(i)}return s||u?(P(s)?s.forEach(e=>l[e]=null):D(l,s),V(t)&&i.set(t,l),l):(V(t)&&i.set(t,null),null)}(r,i),emit:null,emitted:null,propsDefaults:E,inheritAttrs:r.inheritAttrs,ctx:E,data:E,props:E,attrs:E,slots:E,refs:E,setupState:E,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return a.ctx={_:a},a.root=t?t.root:a,a.emit=rH.bind(null,a),e.ce&&e.ce(a),a}(e,r,i);nI(e)&&(l.ctx.renderer=ed),!function(e,t=!1,n=!1){t&&d(t);let{props:r,children:i}=e.vnode,a=iA(e);!function(e,t,n,r=!1){let i={},a=rm();for(let n in e.propsDefaults=Object.create(null),ry(e,t,i,a),e.propsOptions[0])n in i||(i[n]=void 0);n?e.props=r?i:td(i):e.type.props?e.props=i:e.props=a,e.attrs=a}(e,r,a,t),rO(e,i,n),a&&function(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,n4);let{setup:r}=n;if(r){eU();let n=e.setupContext=r.length>1?iR(e):null,i=iE(e),a=tP(r,e,0,[e.props,n]),s=H(a);if(eL(),i(),(s||e.sp)&&!nC(e)&&n_(e),s){if(a.then(iT,iT),t)return a.then(n=>{iC(e,n,t)}).catch(t=>{tM(t,e,0)});e.asyncDep=a}else iC(e,a,t)}else iI(e,t)}(e,t),t&&d(!1)}(l,!1,s),l.asyncDep?(i&&i.registerDep(l,q,s),e.el||x(null,l.subTree=id(r3),t,n)):q(l,e,t,n,i,a,s)},W=(e,t,n)=>{let r=t.component=e.component;if(function(e,t,n){let{props:r,children:i,component:a}=e,{props:s,children:l,patchFlag:u}=t,c=a.emitsOptions;if(t.dirs||t.transition)return!0;if(!n||!(u>=0))return(!!i||!!l)&&(!l||!l.$stable)||r!==s&&(r?!s||rZ(r,s,c):!!s);if(1024&u)return!0;if(16&u)return r?rZ(r,s,c):!!s;if(8&u){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(s[n]!==r[n]&&!rW(c,n))return!0}}return!1}(e,t,n))if(r.asyncDep&&!r.asyncResolved)return void K(r,t,n);else r.next=t,r.update();else t.el=e.el,r.vnode=t},q=(e,t,n,r,a,s,l)=>{let u=()=>{if(e.isMounted){let t,{next:n,bu:r,u:i,parent:c,vnode:d}=e;{let t=function e(t){let n=t.subTree.component;if(n)if(n.asyncDep&&!n.asyncResolved)return n;else return e(n)}(e);if(t){n&&(n.el=d.el,K(e,n,l)),t.asyncDep.then(()=>{e.isUnmounted||u()});return}}let f=n;rR(e,!1),n?(n.el=d.el,K(e,n,l)):n=d,r&&ea(r),(t=n.props&&n.props.onVnodeBeforeUpdate)&&ib(t,c,n,d),rR(e,!0);let h=rq(e),p=e.subTree;e.subTree=h,b(p,h,m(p.el),eo(p),e,a,s),n.el=h.el,null===f&&r$(e,h.el),i&&rI(i,a),(t=n.props&&n.props.onVnodeUpdated)&&rI(()=>ib(t,c,n,d),a)}else{let l,{el:u,props:c}=t,{bm:d,m:f,parent:h,root:p,type:m}=e,g=nC(t);if(rR(e,!1),d&&ea(d),!g&&(l=c&&c.onVnodeBeforeMount)&&ib(l,h,t),rR(e,!0),u&&i){let t=()=>{e.subTree=rq(e),i(u,e.subTree,e,a,null)};g&&m.__asyncHydrate?m.__asyncHydrate(u,e,t):t()}else{p.ce&&p.ce._injectChildStyle(m);let i=e.subTree=rq(e);b(null,i,n,r,e,a,s),t.el=i.el}if(f&&rI(f,a),!g&&(l=c&&c.onVnodeMounted)){let e=t;rI(()=>ib(l,h,e),a)}(256&t.shapeFlag||h&&nC(h.vnode)&&256&h.vnode.shapeFlag)&&e.a&&rI(e.a,a),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new ex(u);e.scope.off();let d=e.update=c.run.bind(c),f=e.job=c.runIfDirty.bind(c);f.i=e,f.id=e.uid,c.scheduler=()=>tq(f),rR(e,!0),d()},K=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:s}}=e,l=ty(i),[u]=e.propsOptions,c=!1;if((r||s>0)&&!(16&s)){if(8&s){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let s=n[r];if(rW(e.emitsOptions,s))continue;let d=t[s];if(u)if(L(a,s))d!==a[s]&&(a[s]=d,c=!0);else{let t=X(s);i[t]=r_(u,l,t,d,e,!1)}else d!==a[s]&&(a[s]=d,c=!0)}}}else{let r;for(let s in ry(e,t,i,a)&&(c=!0),l)t&&(L(t,s)||(r=et(s))!==s&&L(t,r))||(u?n&&(void 0!==n[s]||void 0!==n[r])&&(i[s]=r_(u,l,s,void 0,e,!0)):delete i[s]);if(a!==l)for(let e in a)t&&L(t,e)||(delete a[e],c=!0)}c&&eH(e.attrs,"set","")}(e,t.props,r,n),rC(e,t.children,n),eU(),tZ(e),eL()},J=(e,t,n,r,i,a,s,l,u=!1)=>{let c=e&&e.children,d=e?e.shapeFlag:0,f=t.children,{patchFlag:h,shapeFlag:m}=t;if(h>0){if(128&h)return void Y(c,f,n,r,i,a,s,l,u);else if(256&h)return void Z(c,f,n,r,i,a,s,l,u)}8&m?(16&d&&es(c,i,a),f!==c&&p(n,f)):16&d?16&m?Y(c,f,n,r,i,a,s,l,u):es(c,i,a,!0):(8&d&&p(n,""),16&m&&U(f,n,r,i,a,s,l,u))},Z=(e,t,n,r,i,a,s,l,u)=>{let c;e=e||T,t=t||T;let d=e.length,f=t.length,h=Math.min(d,f);for(c=0;c<h;c++){let r=t[c]=u?iy(t[c]):ig(t[c]);b(e[c],r,n,null,i,a,s,l,u)}d>f?es(e,i,a,!0,!1,h):U(t,n,r,i,a,s,l,u,h)},Y=(e,t,n,r,i,a,s,l,u)=>{let c=0,d=t.length,f=e.length-1,h=d-1;for(;c<=f&&c<=h;){let r=e[c],d=t[c]=u?iy(t[c]):ig(t[c]);if(io(r,d))b(r,d,n,null,i,a,s,l,u);else break;c++}for(;c<=f&&c<=h;){let r=e[f],c=t[h]=u?iy(t[h]):ig(t[h]);if(io(r,c))b(r,c,n,null,i,a,s,l,u);else break;f--,h--}if(c>f){if(c<=h){let e=h+1,f=e<d?t[e].el:r;for(;c<=h;)b(null,t[c]=u?iy(t[c]):ig(t[c]),n,f,i,a,s,l,u),c++}}else if(c>h)for(;c<=f;)ee(e[c],i,a,!0),c++;else{let p,m=c,g=c,y=new Map;for(c=g;c<=h;c++){let e=t[c]=u?iy(t[c]):ig(t[c]);null!=e.key&&y.set(e.key,c)}let _=0,w=h-g+1,x=!1,k=0,S=Array(w);for(c=0;c<w;c++)S[c]=0;for(c=m;c<=f;c++){let r,d=e[c];if(_>=w){ee(d,i,a,!0);continue}if(null!=d.key)r=y.get(d.key);else for(p=g;p<=h;p++)if(0===S[p-g]&&io(d,t[p])){r=p;break}void 0===r?ee(d,i,a,!0):(S[r-g]=c+1,r>=k?k=r:x=!0,b(d,t[r],n,null,i,a,s,l,u),_++)}let E=x?function(e){let t,n,r,i,a,s=e.slice(),l=[0],u=e.length;for(t=0;t<u;t++){let u=e[t];if(0!==u){if(e[n=l[l.length-1]]<u){s[t]=n,l.push(t);continue}for(r=0,i=l.length-1;r<i;)e[l[a=r+i>>1]]<u?r=a+1:i=a;u<e[l[r]]&&(r>0&&(s[t]=l[r-1]),l[r]=t)}}for(r=l.length,i=l[r-1];r-- >0;)l[r]=i,i=s[i];return l}(S):T;for(p=E.length-1,c=w-1;c>=0;c--){let e=g+c,f=t[e],h=e+1<d?t[e+1].el:r;0===S[c]?b(null,f,n,h,i,a,s,l,u):x&&(p<0||c!==E[p]?Q(f,n,h,2):p--)}}},Q=(e,t,n,r,i=null)=>{let{el:s,type:l,transition:u,children:c,shapeFlag:d}=e;if(6&d)return void Q(e.component.subTree,t,n,r);if(128&d)return void e.suspense.move(t,n,r);if(64&d)return void l.move(e,t,n,ed);if(l===r2){a(s,t,n);for(let e=0;e<c.length;e++)Q(c[e],t,n,r);a(e.anchor,t,n);return}if(l===r6)return void S(e,t,n);if(2!==r&&1&d&&u)if(0===r)u.beforeEnter(s),a(s,t,n),rI(()=>u.enter(s),i);else{let{leave:e,delayLeave:r,afterLeave:i}=u,l=()=>a(s,t,n),c=()=>{e(s,()=>{l(),i&&i()})};r?r(s,l,c):c()}else a(s,t,n)},ee=(e,t,n,r=!1,i=!1)=>{let a,{type:s,props:l,ref:u,children:c,dynamicChildren:d,shapeFlag:f,patchFlag:h,dirs:p,cacheIndex:m}=e;if(-2===h&&(i=!1),null!=u&&nb(u,null,n,e,!0),null!=m&&(t.renderCache[m]=void 0),256&f)return void t.ctx.deactivate(e);let g=1&f&&p,y=!nC(e);if(y&&(a=l&&l.onVnodeBeforeUnmount)&&ib(a,t,e),6&f)ei(e.component,n,r);else{if(128&f)return void e.suspense.unmount(n,r);g&&t3(e,null,t,"beforeUnmount"),64&f?e.type.remove(e,t,n,ed,r):d&&!d.hasOnce&&(s!==r2||h>0&&64&h)?es(d,t,n,!1,!0):(s===r2&&384&h||!i&&16&f)&&es(c,t,n),r&&en(e)}(y&&(a=l&&l.onVnodeUnmounted)||g)&&rI(()=>{a&&ib(a,t,e),g&&t3(e,null,t,"unmounted")},n)},en=e=>{let{type:t,el:n,anchor:r,transition:i}=e;if(t===r2)return void er(n,r);if(t===r6)return void O(e);let a=()=>{s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(1&e.shapeFlag&&i&&!i.persisted){let{leave:t,delayLeave:r}=i,s=()=>t(n,a);r?r(e.el,a,s):s()}else a()},er=(e,t)=>{let n;for(;e!==t;)n=g(e),s(e),e=n;s(t)},ei=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:s,um:l,m:u,a:c}=e;rP(u),rP(c),r&&ea(r),i.stop(),a&&(a.flags|=8,ee(s,e,t,n)),l&&rI(l,t),rI(()=>{e.isUnmounted=!0},t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},es=(e,t,n,r=!1,i=!1,a=0)=>{for(let s=a;s<e.length;s++)ee(e[s],t,n,r,i)},eo=e=>{if(6&e.shapeFlag)return eo(e.component.subTree);if(128&e.shapeFlag)return e.suspense.next();let t=g(e.anchor||e.el),n=t&&t[t6];return n?g(n):t},el=!1,ec=(e,t,n)=>{null==e?t._vnode&&ee(t._vnode,null,null,!0):b(t._vnode||null,e,t,null,null,null,n),t._vnode=e,el||(el=!0,tZ(),t$(),el=!1)},ed={p:b,um:ee,m:Q,r:en,mt:G,mc:U,pc:J,pbc:M,n:eo,o:e};return{render:ec,hydrate:r,createApp:(n=r,function(e,t=null){j(e)||(e=D({},e)),null==t||V(t)||(t=null);let r=rc(),i=new WeakSet,a=[],s=!1,l=r.app={_uid:rd++,_component:e,_props:t,_container:null,_context:r,_instance:null,version:iz,get config(){return r.config},set config(v){},use:(e,...t)=>(i.has(e)||(e&&j(e.install)?(i.add(e),e.install(l,...t)):j(e)&&(i.add(e),e(l,...t))),l),mixin:e=>(r.mixins.includes(e)||r.mixins.push(e),l),component:(e,t)=>t?(r.components[e]=t,l):r.components[e],directive:(e,t)=>t?(r.directives[e]=t,l):r.directives[e],mount(i,a,u){if(s);else{let c=l._ceVNode||id(e,t);return c.appContext=r,!0===u?u="svg":!1===u&&(u=void 0),a&&n?n(c,i):ec(c,i,u),s=!0,l._container=i,i.__vue_app__=l,iU(c.component)}},onUnmount(e){a.push(e)},unmount(){s&&(tB(a,l._instance,16),ec(null,l._container),delete l._container.__vue_app__)},provide:(e,t)=>(r.provides[e]=t,l),runWithContext(e){let t=rf;rf=l;try{return e()}finally{rf=t}}};return l})}}(aR))}let aL=(...e)=>{aU().render(...e)},aP=(...e)=>{let t=aU().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=function(e){return z(e)?document.querySelector(e):e}(e);if(!r)return;let i=t._component;j(i)||i.render||i.template||(i.template=r.innerHTML),1===r.nodeType&&(r.textContent="");let a=n(r,!1,function(e){return e instanceof SVGElement?"svg":"function"==typeof MathMLElement&&e instanceof MathMLElement?"mathml":void 0}(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),a},t};var aB,aM,aN,aF,aj=n(558);let az=["innerHTML"];function aG(e){if(void 0!==e.remove)e.remove();else{var t;null==(t=e.parentNode)||t.removeChild(e)}}function aV(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class aH{pause(){this.stop(),this.delay-=Date.now()-this.startedAt}resume(){this.stop(),this.startedAt=Date.now(),this.timer=setTimeout(this.callback,this.delay)}stop(){clearTimeout(this.timer)}constructor(e,t){aV(this,"startedAt",void 0),aV(this,"callback",void 0),aV(this,"delay",void 0),aV(this,"timer",void 0),this.startedAt=Date.now(),this.callback=e,this.delay=t,this.timer=setTimeout(e,t)}}let aW=Object.freeze({TOP_RIGHT:"top-right",TOP:"top",TOP_LEFT:"top-left",BOTTOM_RIGHT:"bottom-right",BOTTOM:"bottom",BOTTOM_LEFT:"bottom-left"}),aq=function(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r?r.push(n):e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var r=e.get(t);r&&r.slice().map(function(e){e(n)}),(r=e.get("*"))&&r.slice().map(function(e){e(t,n)})}}}(),aK=ny({name:"Toast",props:{message:{type:String,required:!0},type:{type:String,default:"success"},position:{type:String,default:aW.BOTTOM_RIGHT,validator:e=>Object.values(aW).includes(e)},duration:{type:Number,default:3e3},dismissible:{type:Boolean,default:!0},onDismiss:{type:Function,default:()=>{}},onClick:{type:Function,default:()=>{}},queue:Boolean,pauseOnHover:{type:Boolean,default:!0}},data:()=>({isActive:!1,parentTop:null,parentBottom:null,isHovered:!1}),beforeMount(){this.setupContainer()},mounted(){this.showNotice(),aq.on("toast-clear",this.dismiss)},methods:{setupContainer(){if(this.parentTop=document.querySelector(".v-toast.v-toast--top"),this.parentBottom=document.querySelector(".v-toast.v-toast--bottom"),this.parentTop&&this.parentBottom)return;this.parentTop||(this.parentTop=document.createElement("div"),this.parentTop.className="v-toast v-toast--top"),this.parentBottom||(this.parentBottom=document.createElement("div"),this.parentBottom.className="v-toast v-toast--bottom");let e=document.body;e.appendChild(this.parentTop),e.appendChild(this.parentBottom)},shouldQueue(){return!!this.queue&&(this.parentTop.childElementCount>0||this.parentBottom.childElementCount>0)},dismiss(){this.timer&&this.timer.stop(),clearTimeout(this.queueTimer),this.isActive=!1,setTimeout(()=>{this.onDismiss.apply(null,arguments);let e=this.$refs.root;aL(null,e),aG(e)},150)},showNotice(){if(this.shouldQueue()){this.queueTimer=setTimeout(this.showNotice,250);return}let e=this.$refs.root.parentElement;this.correctParent.insertAdjacentElement("afterbegin",this.$refs.root),aG(e),this.isActive=!0,this.duration&&(this.timer=new aH(this.dismiss,this.duration))},whenClicked(){this.dismissible&&(this.onClick.apply(null,arguments),this.dismiss())},toggleTimer(e){this.pauseOnHover&&this.timer&&(e?this.timer.pause():this.timer.resume())}},computed:{correctParent(){switch(this.position){case aW.TOP:case aW.TOP_RIGHT:case aW.TOP_LEFT:return this.parentTop;case aW.BOTTOM:case aW.BOTTOM_RIGHT:case aW.BOTTOM_LEFT:return this.parentBottom}},transition(){switch(this.position){case aW.TOP:case aW.TOP_RIGHT:case aW.TOP_LEFT:return{enter:"v-toast--fade-in-down",leave:"v-toast--fade-out"};case aW.BOTTOM:case aW.BOTTOM_RIGHT:case aW.BOTTOM_LEFT:return{enter:"v-toast--fade-in-up",leave:"v-toast--fade-out"}}}},beforeUnmount(){aq.off("toast-clear",this.dismiss)}});var aJ=n(231);let aZ=(0,aJ.default)(aK,[["render",function(e,t,n,r,i,a){return r9(),ia(iY,{"enter-active-class":e.transition.enter,"leave-active-class":e.transition.leave},{default:t2(()=>[t5(ic("div",{ref:"root",role:"alert",class:ep(["v-toast__item",[`v-toast__item--${e.type}`,`v-toast__item--${e.position}`]]),onMouseover:t[0]||(t[0]=t=>e.toggleTimer(!0)),onMouseleave:t[1]||(t[1]=t=>e.toggleTimer(!1)),onClick:t[2]||(t[2]=function(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.whenClicked&&e.whenClicked(...n)})},[t[3]||(t[3]=ic("div",{class:"v-toast__icon"},null,-1)),ic("p",{class:"v-toast__text",innerHTML:e.message},null,8,az)],34),[[at,e.isActive]])]),_:1},8,["enter-active-class","leave-active-class"])}]]),a$=("undefined"!=typeof globalThis?globalThis:void 0)?.crypto||("undefined"!=typeof global?global:void 0)?.crypto||("undefined"!=typeof window?window:void 0)?.crypto||("undefined"!=typeof self?self:void 0)?.crypto||("undefined"!=typeof frames?frames:void 0)?.[0]?.crypto;m=a$?e=>{let t=[];for(let n=0;n<e;n+=4)t.push(a$.getRandomValues(new Uint32Array(1))[0]);return new aQ(t,e)}:e=>{let t=[],n=e=>{let t=e,n=0x3ade68b1;return()=>{let e=((n=36969*(65535&n)+(n>>16)&0xffffffff)<<16)+(t=18e3*(65535&t)+(t>>16)&0xffffffff)&0xffffffff;return e/=0x100000000,(e+=.5)*(Math.random()>.5?1:-1)}};for(let r=0,i;r<e;r+=4){let e=n(0x100000000*(i||Math.random()));i=0x3ade67b7*e(),t.push(0x100000000*e()|0)}return new aQ(t,e)};class aY{static create(...e){return new this(...e)}mixIn(e){return Object.assign(this,e)}clone(){let e=new this.constructor;return Object.assign(e,this),e}}class aQ extends aY{constructor(e=[],t=4*e.length){super();let n=e;if(n instanceof ArrayBuffer&&(n=new Uint8Array(n)),(n instanceof Int8Array||n instanceof Uint8ClampedArray||n instanceof Int16Array||n instanceof Uint16Array||n instanceof Int32Array||n instanceof Uint32Array||n instanceof Float32Array||n instanceof Float64Array)&&(n=new Uint8Array(n.buffer,n.byteOffset,n.byteLength)),n instanceof Uint8Array){let e=n.byteLength,t=[];for(let r=0;r<e;r+=1)t[r>>>2]|=n[r]<<24-r%4*8;this.words=t,this.sigBytes=e}else this.words=e,this.sigBytes=t}static random=m;toString(e=aX){return e.stringify(this)}concat(e){let t=this.words,n=e.words,r=this.sigBytes,i=e.sigBytes;if(this.clamp(),r%4)for(let e=0;e<i;e+=1){let i=n[e>>>2]>>>24-e%4*8&255;t[r+e>>>2]|=i<<24-(r+e)%4*8}else for(let e=0;e<i;e+=4)t[r+e>>>2]=n[e>>>2];return this.sigBytes+=i,this}clamp(){let{words:e,sigBytes:t}=this;e[t>>>2]&=0xffffffff<<32-t%4*8,e.length=Math.ceil(t/4)}clone(){let e=super.clone.call(this);return e.words=this.words.slice(0),e}}let aX={stringify(e){let{words:t,sigBytes:n}=e,r=[];for(let e=0;e<n;e+=1){let n=t[e>>>2]>>>24-e%4*8&255;r.push((n>>>4).toString(16)),r.push((15&n).toString(16))}return r.join("")},parse(e){let t=e.length,n=[];for(let r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new aQ(n,t/2)}},a0={stringify(e){let{words:t,sigBytes:n}=e,r=[];for(let e=0;e<n;e+=1){let n=t[e>>>2]>>>24-e%4*8&255;r.push(String.fromCharCode(n))}return r.join("")},parse(e){let t=e.length,n=[];for(let r=0;r<t;r+=1)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new aQ(n,t)}},a1={stringify(e){try{return decodeURIComponent(escape(a0.stringify(e)))}catch(e){throw Error("Malformed UTF-8 data")}},parse:e=>a0.parse(unescape(encodeURIComponent(e)))};class a2 extends aY{constructor(){super(),this._minBufferSize=0}reset(){this._data=new aQ,this._nDataBytes=0}_append(e){let t=e;"string"==typeof t&&(t=a1.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes}_process(e){let t,{_data:n,blockSize:r}=this,i=n.words,a=n.sigBytes,s=a/(4*r),l=(s=e?Math.ceil(s):Math.max((0|s)-this._minBufferSize,0))*r,u=Math.min(4*l,a);if(l){for(let e=0;e<l;e+=r)this._doProcessBlock(i,e);t=i.splice(0,l),n.sigBytes-=u}return new aQ(t,u)}clone(){let e=super.clone.call(this);return e._data=this._data.clone(),e}}class a5 extends a2{constructor(e){super(),this.blockSize=16,this.cfg=Object.assign(new aY,e),this.reset()}static _createHelper(e){return(t,n)=>new e(n).finalize(t)}static _createHmacHelper(e){return(t,n)=>new a3(e,n).finalize(t)}reset(){super.reset.call(this),this._doReset()}update(e){return this._append(e),this._process(),this}finalize(e){return e&&this._append(e),this._doFinalize()}}class a3 extends aY{constructor(e,t){super();let n=new e;this._hasher=n;let r=t;"string"==typeof r&&(r=a1.parse(r));let i=n.blockSize,a=4*i;r.sigBytes>a&&(r=n.finalize(t)),r.clamp();let s=r.clone();this._oKey=s;let l=r.clone();this._iKey=l;let u=s.words,c=l.words;for(let e=0;e<i;e+=1)u[e]^=0x5c5c5c5c,c[e]^=0x36363636;s.sigBytes=a,l.sigBytes=a,this.reset()}reset(){let e=this._hasher;e.reset(),e.update(this._iKey)}update(e){return this._hasher.update(e),this}finalize(e){let t=this._hasher,n=t.finalize(e);return t.reset(),t.finalize(this._oKey.clone().concat(n))}}let a6=[];for(let e=0;e<64;e+=1)a6[e]=0x100000000*Math.abs(Math.sin(e+1))|0;let a4=(e,t,n,r,i,a,s)=>{let l=e+(t&n|~t&r)+i+s;return(l<<a|l>>>32-a)+t},a8=(e,t,n,r,i,a,s)=>{let l=e+(t&r|n&~r)+i+s;return(l<<a|l>>>32-a)+t},a9=(e,t,n,r,i,a,s)=>{let l=e+(t^n^r)+i+s;return(l<<a|l>>>32-a)+t},a7=(e,t,n,r,i,a,s)=>{let l=e+(n^(t|~r))+i+s;return(l<<a|l>>>32-a)+t};class se extends a5{_doReset(){this._hash=new aQ([0x67452301,0xefcdab89,0x98badcfe,0x10325476])}_doProcessBlock(e,t){for(let n=0;n<16;n+=1){let r=t+n,i=e[r];e[r]=(i<<8|i>>>24)&0xff00ff|(i<<24|i>>>8)&0xff00ff00}let n=this._hash.words,r=e[t+0],i=e[t+1],a=e[t+2],s=e[t+3],l=e[t+4],u=e[t+5],c=e[t+6],d=e[t+7],f=e[t+8],h=e[t+9],p=e[t+10],m=e[t+11],g=e[t+12],y=e[t+13],_=e[t+14],b=e[t+15],w=n[0],x=n[1],k=n[2],S=n[3];w=a4(w,x,k,S,r,7,a6[0]),S=a4(S,w,x,k,i,12,a6[1]),k=a4(k,S,w,x,a,17,a6[2]),x=a4(x,k,S,w,s,22,a6[3]),w=a4(w,x,k,S,l,7,a6[4]),S=a4(S,w,x,k,u,12,a6[5]),k=a4(k,S,w,x,c,17,a6[6]),x=a4(x,k,S,w,d,22,a6[7]),w=a4(w,x,k,S,f,7,a6[8]),S=a4(S,w,x,k,h,12,a6[9]),k=a4(k,S,w,x,p,17,a6[10]),x=a4(x,k,S,w,m,22,a6[11]),w=a4(w,x,k,S,g,7,a6[12]),S=a4(S,w,x,k,y,12,a6[13]),k=a4(k,S,w,x,_,17,a6[14]),x=a4(x,k,S,w,b,22,a6[15]),w=a8(w,x,k,S,i,5,a6[16]),S=a8(S,w,x,k,c,9,a6[17]),k=a8(k,S,w,x,m,14,a6[18]),x=a8(x,k,S,w,r,20,a6[19]),w=a8(w,x,k,S,u,5,a6[20]),S=a8(S,w,x,k,p,9,a6[21]),k=a8(k,S,w,x,b,14,a6[22]),x=a8(x,k,S,w,l,20,a6[23]),w=a8(w,x,k,S,h,5,a6[24]),S=a8(S,w,x,k,_,9,a6[25]),k=a8(k,S,w,x,s,14,a6[26]),x=a8(x,k,S,w,f,20,a6[27]),w=a8(w,x,k,S,y,5,a6[28]),S=a8(S,w,x,k,a,9,a6[29]),k=a8(k,S,w,x,d,14,a6[30]),x=a8(x,k,S,w,g,20,a6[31]),w=a9(w,x,k,S,u,4,a6[32]),S=a9(S,w,x,k,f,11,a6[33]),k=a9(k,S,w,x,m,16,a6[34]),x=a9(x,k,S,w,_,23,a6[35]),w=a9(w,x,k,S,i,4,a6[36]),S=a9(S,w,x,k,l,11,a6[37]),k=a9(k,S,w,x,d,16,a6[38]),x=a9(x,k,S,w,p,23,a6[39]),w=a9(w,x,k,S,y,4,a6[40]),S=a9(S,w,x,k,r,11,a6[41]),k=a9(k,S,w,x,s,16,a6[42]),x=a9(x,k,S,w,c,23,a6[43]),w=a9(w,x,k,S,h,4,a6[44]),S=a9(S,w,x,k,g,11,a6[45]),k=a9(k,S,w,x,b,16,a6[46]),x=a9(x,k,S,w,a,23,a6[47]),w=a7(w,x,k,S,r,6,a6[48]),S=a7(S,w,x,k,d,10,a6[49]),k=a7(k,S,w,x,_,15,a6[50]),x=a7(x,k,S,w,u,21,a6[51]),w=a7(w,x,k,S,g,6,a6[52]),S=a7(S,w,x,k,s,10,a6[53]),k=a7(k,S,w,x,p,15,a6[54]),x=a7(x,k,S,w,i,21,a6[55]),w=a7(w,x,k,S,f,6,a6[56]),S=a7(S,w,x,k,b,10,a6[57]),k=a7(k,S,w,x,c,15,a6[58]),x=a7(x,k,S,w,y,21,a6[59]),w=a7(w,x,k,S,l,6,a6[60]),S=a7(S,w,x,k,m,10,a6[61]),k=a7(k,S,w,x,a,15,a6[62]),x=a7(x,k,S,w,h,21,a6[63]),n[0]=n[0]+w|0,n[1]=n[1]+x|0,n[2]=n[2]+k|0,n[3]=n[3]+S|0}_doFinalize(){let e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;t[r>>>5]|=128<<24-r%32;let i=Math.floor(n/0x100000000);t[(r+64>>>9<<4)+15]=(i<<8|i>>>24)&0xff00ff|(i<<24|i>>>8)&0xff00ff00,t[(r+64>>>9<<4)+14]=(n<<8|n>>>24)&0xff00ff|(n<<24|n>>>8)&0xff00ff00,e.sigBytes=(t.length+1)*4,this._process();let a=this._hash,s=a.words;for(let e=0;e<4;e+=1){let t=s[e];s[e]=(t<<8|t>>>24)&0xff00ff|(t<<24|t>>>8)&0xff00ff00}return a}clone(){let e=super.clone.call(this);return e._hash=this._hash.clone(),e}}let st=a5._createHelper(se);a5._createHmacHelper(se);let sn=(e,t)=>{let n=-1,r=e.length,i=Array(r);for(;++n<r;)i[n]=t(e[n]);return i},sr=(e,t)=>{let n=-1,r=e.length;for(;++n<r;)t(e[n])},si=e=>{if(e.scrollTop>0)return!0;e.scrollTop=1;let t=!!e.scrollTop;return e.scrollTop=0,t},sa=async(e,t,n)=>{let r=[],i=[];for(let a of e){let s=Promise.resolve().then(()=>n(a));if(r.push(s),t<=e.length){let e=s.then(()=>i.splice(i.indexOf(e),1));i.push(e),i.length>=t&&await Promise.race(i)}}return Promise.all(r)},ss=e=>{let t="",n=-1;for(;++n<13;)t+=10*Math.random()|0;let r=(Date.now()%1e10*1e3+(1e3*Math.random()|0)%0xffffffff).toString(),i=new URLSearchParams(e.code),a=i.get("fs"),s=(Date.now()/1e3|21600).toString(16),l=(Date.now()+Number(t)).toString(),u=atob(i.get("fm")).split("_")[0],c=st(`${l}|tars_mp|102`).toString(),d=st([u,t,e.name,c,s].join("_")).toString();return`&wsSecret=${d}&uuid=${r}&wsTime=${s}&uid=${t}&seqid=${l}&fs=${a}&ctype=tars_mp&t=102&ver=1&sv=2401310321`},so=()=>{let e=new Date,t=e=>e.toString().padStart(2,"0");return`${e.getFullYear()}-${t(e.getMonth()+1)}-${t(e.getDate())} ${t(e.getHours())}:${t(e.getMinutes())}:${t(e.getSeconds())}`},sl="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=",su="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/mzPLByY8jS1Fpr/n95fTqjPrF0WnW17m6aaZ8tnvCzzNAYVj7pDAAlB82fNWSV1teVUoDPlRAxhfaT3aozynUV6lwGzf2rp/QD6rJfw1uf4PW9CPLLVS0g96+G1AJK7I6rV1Osc/W0ZVNJUaDrn7g9DHlTN4J3ClSqstkhw8wxCCtDvy3WsH3zasAr2lgFrw5FWDyJ9tHOn57oEz2YFnlVcz+qpB5GO88u0SlsGvrC58Obt5UlcPIp1FL/StbQUvcQO1dycteNrKQeSPBe5APOjK0E0Nldp+hMemcIKQK5yS7jiv+1rwsSiYbOCumHEpJQQRhqRzvJwtM7rNhV+b3z8pEsv1ILTCX2a3T39VWYW6qFJIhvCUVIMIY1bFl0mlLSx/wxN02zjj730XdwaB38jw4b0BMVJpby3hmYYURMQL0oJfhb+Jz8UkiAM/hwLpwDOMSZCayvuoJjz5mAQZKrR1jvAZxyTIRvwgb18zi0mQrcKB4h4+7+EESRvf0v+uWrwTp4I2UjrsHQrmIQWhb2nxqoME6cPPpSDeOZuBIgSRBJnzzkXFUdwzNnNRBsnCz+K3GT/pR0cTck7IQerg91E2jA3zHg8akSf42fy3TxjrKdIRGcDvjYJ4hqfBPfqN6vZ7VAhSY4xhD1c4IRdEeoNPg/04Ygb8Ack6fSnsIA3+GnHgWdHPfl19/go7iMm/a00ZlaeFEyfyIBZ8VuyGaTPgoVg18iArfmVfMHZnB5wYkQdx+XutHaMb5OJkHnmQP+2d6XabMBCFB7NjMN4a8AYJXuJ43+JW7/9iPW3/VJWFZmTcQ87x999Jbiykq9Ho0qe73yb3o3FHW+nDhUzp+5EL/hOpwsRRF0SszQ5wQvAPe0ehl2pRsBcF38hDK8Sdv2wfL8Shn+v6eOPvKsp4VCHYPg6bfCHPw1WJo8cLgSa5avhDcGfK79v9D0IglIx3XJkV14gq8kKftfovGerf1tTKK0lRa6fIiriOeOYelNjx29Fx9ZKJEs3WeYckpDeyoXpyfDnoncloU4R8nuEROPiJrstkxHghwzE8hghfMmVSBmgh367wIAboIvaVSbGQQjwLbpKcCzuF+7DQ/SsLJmWME9IvBAWvo20j7P1R2d+8zVzQZcfQPTX/YgqfY6VsbOAozIAJ9LaxfX936lgzU84QtIo9BYbBDZ5zyaXNhnm9876FpSlkr157Xvghpbjt+B4Blbk4+9CFzIlC2iFT0RBGB6WeG2kKmSiF+H/PLwHDsC2Agi1aDbqQhUqIr/SeyvguUrdarinELhPC68iODM8S8CT6YWom59EMDm7WGp64MDoCAaBJxW0+XUhS2pbWM7g5koRna6XkbTSFZKVC2twnqBQ6LY1DTSFpmRCf2/TTuQIHqjrpaQqBMiEFt2QJ9JeraGy8rkbHhsSh6VzP+g4EvnF1f0N1N/3aYgL+Lvn7eXVnt8R8aAQ0dbRC6YISIa2OfKe83INAsWUCOf2S7lzr2rhfIiSXZgP+kPyysah4QE613AGBNTd6bgvpZdy+B9cXl0u+1nIGumYrPXBWwij/QgLKgIkPjGdG3ZC8aLk0C3UKTlHSadGzrCa6cZZ7wpqVhJK6npQh+frxSTenukmY62Zke5v2+GdtQvMoU63wdFBx7srcC7pf5JPmUdaAJDMpH/om92HoFNgFyaMcyp+mYGk6g507WB27JK89ZFIibLyJQ/MoiUYn4CdhPhGJkbG0F5pHmWiMkFdSfdkXlm1kUotN8ihjekTSkBYdM7DQ/4gxbWyt0Ltk25MWftFF43UGghIL1QARkDxKi5xmE9HSNs1bGywLlW55Il3p39Fiq9Yx0V/bQFBikSI5UjGWVK6ZZ/uagJot34BCUJIJ3z1+wBwWOMu0viyjhJ7xsZUlflvKjzKTlnVtYo4WFpQ9cchtW0lKjsJEhD/BORRQMT1un0BSMqIVq6YPfVNLIhnnMUKJQyunONS9vn69fwwkJRat27Tj4ZcGOgV/uEdS4hI7sj/U9kcfW24RI5WSNrFtthAMbQKVkfLDlqRkJPEoeO8xjKEyPG76JSnxhSIy/U0Ol10G1dDn/hiSkpBcOo2ZSK9hulWI2ZROoe0SJbbGbPpD1gSzafpvy4/RLF+1o4G1c/fzyaJzuqaa8f82Tol++E4yZFUR+qOTtBYUAVKJOJu6gKLwWHW8u7LFYIt5a4516yDigPV3BqsQz5aYLa+DVxJrWifjUdnDWz4BH61kg1ilH6/kJJkSD3OsEkM4oEBzCllluLJZ9Ih7+ZgFwT2RjUtWFStpf6qFVHKf/5sdWDXE0sCsnqFUItJK6DH+XaaL7Djy+s5PaSnmxO3+TZI9a1WwkmQljioEqpIwAR2SuMnuZF/axT2lKlmBLqd2Y830MRW3Y8OFugJYXXxket45v16fcvSbl2Daf1973R7DMDVuVOl4umOKkjZUT5Z07MWkMOScT5hNKDvO0UqG36E+OOIrOkYdcc7Mb/UCF1Anlkygu8kn/HMpafSuF8Htla75mQ+M2DwGLemBad3wmA5LqB020yCEGlIwMh7UkmufyanxG+7k1VmRmr2zVk3O0BzqN1/9zQDrrYcu1Bvcq7L67Tr5EgmLbyrzGa4y+BJMPlkJrTyBL8PCubCbdN9ev5CM39hOIExUx/EXGVP/cNpF5nLT9w7rwP/IY/cLPOBPnjx58uTJk6r5CXO8FpZU+7yPAAAAAElFTkSuQmCC",sc="https://live.muxia.fun/api2/",sd=(e,t,n)=>("douyin"==e&&(n?n.cookie=sI[e]:n={cookie:sI[e]}),sp(`${sc}${e}/${t}${n?"?"+new URLSearchParams(n).toString():""}`)),sf=async e=>{let t=Object.keys(e.follows);if(!t.length)return Promise.resolve(!1);"douyin"==e.id?(await sa(t,4,e=>sd("douyin","getLiveStatus",{id:e}))).forEach((n,r)=>{let i=e.follows[t[r]],a=n[t[r]];i.status=a.status,a.avatar&&(i.avatar=a.avatar),a.title&&(i.title=a.title),a.cover&&(i.cover=a.cover),a.nickname&&(i.nickname=a.nickname),a.category&&i.category,a.cid&&(i.cid=a.cid),a.online&&(i.online=a.online)}):await sd(e.id,"getLiveStatus",{id:t.join(",")}).then(t=>Object.keys(t).forEach(n=>{let r=e.follows[n],i=t[n];r.status=i.status,i.avatar&&(r.avatar=i.avatar),i.title&&(r.title=i.title),i.cover&&(r.cover=i.cover),i.nickname&&(r.nickname=i.nickname),i.category&&(r.category=i.category),i.cid&&(r.cid=i.cid),i.online&&(r.online=i.online)})),sA("follows-"+e.id,e.follows)},sh=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{open(t){let n=null;return"string"==typeof t&&(n=t),{dismiss:function(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=ij(e,t,r),a=document.createElement("div");return a.classList.add("v-toast--pending"),n.appendChild(a),aL(i,a),i.component}(aZ,Object.assign({},{message:n},e,t),document.body).ctx.dismiss}},clear(){aq.emit("toast-clear")},success(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.open(Object.assign({},{message:e,type:"success"},t))},error(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.open(Object.assign({},{message:e,type:"error"},t))},info(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.open(Object.assign({},{message:e,type:"info"},t))},warning(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.open(Object.assign({},{message:e,type:"warning"},t))},default(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.open(Object.assign({},{message:e,type:"default"},t))}}}({duration:3e3,position:"top"}),sp=(e,t)=>fetch(e,t).then(async e=>{let t=await e.text();return 200!=(t=JSON.parse((0,aj.decompressFromBase64)(t))).code?(sh.error(t.msg),Promise.reject(t.msg)):t.data},e=>{sh.error("请求异常!")}),sv=(e,t)=>sp(`${sc}sync/${e}`,{body:JSON.stringify(t),method:"POST",headers:{token:sB.token||""}}),sm={huya:"虎牙",bilibili:"哔哩",douyu:"斗鱼",douyin:"抖音"},sg=[{name:"虎牙直播",icon:"https://www.huya.com/favicon.ico",id:"huya",categories:tx([]),categoryActive:tx(0),recommend:{page:1,hasMore:!0,list:tx([])},search:{page:1,hasMore:!0,list:tx([])},follows:tc(sk("huya"))},{name:"斗鱼直播",icon:"https://www.douyu.com/favicon.ico",id:"douyu",categories:tx([]),categoryActive:tx(0),recommend:{page:1,hasMore:!0,list:tx([])},search:{page:1,hasMore:!0,list:tx([])},follows:tc(sk("douyu"))},{name:"抖音直播",icon:"https://www.douyin.com/favicon.ico",id:"douyin",categories:tx([]),categoryActive:tx(0),recommend:{page:1,hasMore:!0,list:tx([])},search:{page:1,hasMore:!0,list:tx([])},follows:tc(sk("douyin"))},{name:"哔哩直播",icon:"https://www.bilibili.com/favicon.ico",id:"bilibili",categories:tx([]),categoryActive:tx(0),recommend:{page:1,hasMore:!0,list:tx([])},search:{page:1,hasMore:!0,list:tx([])},follows:tc(sk("bilibili"))}],sy=["huya","douyu","douyin","bilibili"],s_=tx(sT("volume",100)),sb=tx(sT("brightness",100)),sw=e=>{s_.value=e?Math.min(100,s_.value+5):Math.max(0,s_.value-5)},sx=e=>{sb.value=e?Math.min(200,sb.value+10):Math.max(50,sb.value-10)};function sk(e){let t=localStorage.getItem("follows-"+e);return t?JSON.parse(t):{}}async function sS(e,t){let n=e.categories;for(let r of(n.value.length||(n.value=await sd(e.id,"getCategories")),n.value))for(let e of r.list)if(e.cid==t)return e;return null}let sE=tc(sT("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:""}));function sT(e,t){let n=localStorage.getItem(e);try{if(n)return JSON.parse(n)}catch{}return t}function sA(e,t){localStorage.setItem(e,JSON.stringify(t))}rN(()=>{sA("dm-settings",sE)});let 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"],sC=iF(()=>0==sE.blockWords.length?[]:sE.blockWords.split(" ").map(e=>new RegExp(e))),sI=tc(sT("cookies",{}));rN(()=>sA("cookies",sI));let sD=tx(0),sR=tx(sT("show-chat",!0)),sU=tx(sT("show-aside",!0));rN(()=>sA("show-chat",sR.value)),rN(()=>sA("show-aside",sU.value));let sL=sn(sg,e=>({name:e.name,list:iF(()=>Object.values(e.follows).sort(e=>e.status?-1:0))}));sL.unshift({name:"全部",list:iF(()=>sg.map(e=>Object.values(e.follows)).flat().sort(e=>e.status?-1:0))});let sP={huya:0,douyu:1,douyin:2,bilibili:3},sB=tc(sT("login-info",{user:{},token:""})),sM=iF(()=>!!sB.token),sN=e=>sv("sign",e).then(e=>{sB.user=e.user,sB.token=e.token,sA("login-info",sB),sH(!0)}),sF=e=>sv("logout",{token:e}).finally(()=>{if(e==sB.token){sB.user={username:"",token:[]},sB.token="",sA("login-info",sB);return}let t=sB.user.token.findIndex(t=>t.token==e);-1!=t&&(sB.user.token.splice(t,1),sA("login-info",sB))}),sj=e=>sv("reset",e).then(e=>{sB.user=e.user,sB.token=e.token,sA("login-info",sB)}),sz=tx(!0),sG=tx(localStorage.getItem("last-sync")),sV=async()=>{if(!1==sM.value)return;let e=await sv("pull");if(!e)return;let t=[[],[],[],[]];sr(e,e=>{let n=sP[e.site_id],r=sg[n].follows;if(0==e.status)return void delete sg[n].follows[e.room_id];if(t[n].push(e.room_id),r[e.room_id]){if(r[e.room_id].id)return;r[e.room_id].id=e.id;return}r[e.room_id]={id:e.id,sitename:sm[e.site_id],roomId:e.room_id,siteId:e.site_id,status:!1,avatar:"",nickname:e.nickname,title:"",online:"0",cover:"",category:""}});let n=[];if(sg.forEach((e,r)=>{sA("follows-"+e.id,e.follows),sr(Object.keys(e.follows),i=>{-1==t[r].findIndex(e=>e==i)&&n.push({site_id:e.follows[i].siteId,room_id:e.follows[i].roomId,nickname:e.follows[i].nickname})})}),sG.value=so(),0==n.length)return;let r=await sv("push",{follows:n});r&&sr(r,e=>{sg[sP[e.site_id]].follows[e.room_id].id=e.id})},sH=e=>{(e||!sG.value||new Date(sG.value).getMilliseconds()+36e5<Date.now())&&sV().then(()=>{sG.value=so(),localStorage.setItem("last-sync",sG.value),e&&sh.success("同步成功")}).finally(()=>sz.value=!1)};sH();let sW=e=>{let t=sg[sP[e.siteId]].follows;t[e.roomId]={sitename:e.sitename,roomId:e.roomId,siteId:e.siteId,status:e.status,avatar:e.avatar,nickname:e.nickname,title:e.title,online:e.online,cover:e.cover,category:e.category};let n="follows-"+e.siteId;return sM.value&&sv("add",{site_id:e.siteId,room_id:e.roomId,nickname:e.nickname}).then(r=>{t[e.roomId].id=r.id,sA(n,t),sh.success("添加云端关注成功")}),sA(n,t),sh.success("添加本地关注成功"),!0},sq=e=>{let t=sg[sP[e.siteId]].follows,n=t[e.roomId];return e.id=n.id,e.avatar&&(n.avatar=e.avatar),e.title&&(n.title=e.title),e.cover&&(n.cover=e.cover),e.nickname&&(n.nickname=e.nickname),e.category&&n.category,e.cid&&(n.cid=e.cid),e.online&&(n.online=e.online),sA("follows-"+e.siteId,t),e.id},sK=e=>{let t=sg[sP[e.siteId]].follows,n="follows-"+e.siteId;return delete t[e.roomId],sA(n,t),sh.success("取消本地关注成功"),e.id&&sM.value&&sv("remove",{id:e.id}).then(()=>sh.success("取消云端关注成功")),!1},sJ="undefined"!=typeof document;function sZ(e){return"object"==typeof e||"displayName"in e||"props"in e||"__vccOpts"in e}let s$=Object.assign;function sY(e,t){let n={};for(let r in t){let i=t[r];n[r]=sX(i)?i.map(e):e(i)}return n}let sQ=()=>{},sX=Array.isArray,s0=/#/g,s1=/&/g,s2=/\//g,s5=/=/g,s3=/\?/g,s6=/\+/g,s4=/%5B/g,s8=/%5D/g,s9=/%5E/g,s7=/%60/g,oe=/%7B/g,ot=/%7C/g,on=/%7D/g,or=/%20/g;function oi(e){return encodeURI(""+e).replace(ot,"|").replace(s4,"[").replace(s8,"]")}function oa(e){return oi(e).replace(s6,"%2B").replace(or,"+").replace(s0,"%23").replace(s1,"%26").replace(s7,"`").replace(oe,"{").replace(on,"}").replace(s9,"^")}function os(e){return null==e?"":oi(e).replace(s0,"%23").replace(s3,"%3F").replace(s2,"%2F")}function oo(e){try{return decodeURIComponent(""+e)}catch(e){}return""+e}let ol=/\/$/,ou=e=>e.replace(ol,"");function oc(e,t,n="/"){let r,i={},a="",s="",l=t.indexOf("#"),u=t.indexOf("?");return l<u&&l>=0&&(u=-1),u>-1&&(r=t.slice(0,u),i=e(a=t.slice(u+1,l>-1?l:t.length))),l>-1&&(r=r||t.slice(0,l),s=t.slice(l,t.length)),{fullPath:(r=function(e,t){let n,r;if(e.startsWith("/"))return e;if(!e)return t;let i=t.split("/"),a=e.split("/"),s=a[a.length-1];(".."===s||"."===s)&&a.push("");let l=i.length-1;for(n=0;n<a.length;n++)if("."!==(r=a[n]))if(".."===r)l>1&&l--;else break;return i.slice(0,l).join("/")+"/"+a.slice(n).join("/")}(null!=r?r:t,n))+(a&&"?")+a+s,path:r,query:i,hash:oo(s)}}function od(e,t){return t&&e.toLowerCase().startsWith(t.toLowerCase())?e.slice(t.length)||"/":e}function of(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function oh(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let i in e){var n,r;if(n=e[i],r=t[i],sX(n)?!op(n,r):sX(r)?!op(r,n):n!==r)return!1}return!0}function op(e,t){return sX(t)?e.length===t.length&&e.every((e,n)=>e===t[n]):1===e.length&&e[0]===t}let ov={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};!function(e){e.pop="pop",e.push="push"}(aB||(aB={})),function(e){e.back="back",e.forward="forward",e.unknown=""}(aM||(aM={}));let om=/^[^#]+#/;function og(e,t){return e.replace(om,"#")+t}let oy=()=>({left:window.scrollX,top:window.scrollY});function o_(e,t){return(history.state?history.state.position-t:-1)+e}let ob=new Map,ow=()=>location.protocol+"//"+location.host;function ox(e,t){let{pathname:n,search:r,hash:i}=t,a=e.indexOf("#");if(a>-1){let t=i.includes(e.slice(a))?e.slice(a).length:1,n=i.slice(t);return"/"!==n[0]&&(n="/"+n),od(n,"")}return od(n,e)+r+i}function ok(e,t,n,r=!1,i=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:i?oy():null}}function oS(e){return"string"==typeof e||"symbol"==typeof e}let oE=Symbol("");function oT(e,t){return s$(Error(),{type:e,[oE]:!0},t)}function oA(e,t){return e instanceof Error&&oE in e&&(null==t||!!(e.type&t))}!function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"}(aN||(aN={}));let oO="[^/]+?",oC={sensitive:!1,strict:!1,start:!0,end:!0},oI=/[.+*?^${}()[\]/\\]/g;function oD(e,t){let n=0,r=e.score,i=t.score;for(;n<r.length&&n<i.length;){let e=function(e,t){let n=0;for(;n<e.length&&n<t.length;){let r=t[n]-e[n];if(r)return r;n++}return e.length<t.length?1===e.length&&80===e[0]?-1:1:e.length>t.length?1===t.length&&80===t[0]?1:-1:0}(r[n],i[n]);if(e)return e;n++}if(1===Math.abs(i.length-r.length)){if(oR(r))return 1;if(oR(i))return -1}return i.length-r.length}function oR(e){let t=e[e.length-1];return e.length>0&&t[t.length-1]<0}let oU={type:0,value:""},oL=/[a-zA-Z0-9_]/;function oP(e,t){let n={};for(let r of t)r in e&&(n[r]=e[r]);return n}function oB(e){let t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:function(e){let t={},n=e.props||!1;if("component"in e)t.default=n;else for(let r in e.components)t[r]="object"==typeof n?n[r]:n;return t}(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function oM(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function oN(e,t){let n={};for(let r in e)n[r]=r in t?t[r]:e[r];return n}function oF({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function oj(e){let t={};if(""===e||"?"===e)return t;let n=("?"===e[0]?e.slice(1):e).split("&");for(let e=0;e<n.length;++e){let r=n[e].replace(s6," "),i=r.indexOf("="),a=oo(i<0?r:r.slice(0,i)),s=i<0?null:oo(r.slice(i+1));if(a in t){let e=t[a];sX(e)||(e=t[a]=[e]),e.push(s)}else t[a]=s}return t}function oz(e){let t="";for(let n in e){let r=e[n];if(n=oa(n).replace(s5,"%3D"),null==r){void 0!==r&&(t+=(t.length?"&":"")+n);continue}(sX(r)?r.map(e=>e&&oa(e)):[r&&oa(r)]).forEach(e=>{void 0!==e&&(t+=(t.length?"&":"")+n,null!=e&&(t+="="+e))})}return t}let oG=Symbol(""),oV=Symbol(""),oH=Symbol(""),oW=Symbol(""),oq=Symbol("");function oK(){let e=[];return{add:function(t){return e.push(t),()=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)}},list:()=>e.slice(),reset:function(){e=[]}}}function oJ(e,t,n,r,i,a=e=>e()){let s=r&&(r.enterCallbacks[i]=r.enterCallbacks[i]||[]);return()=>new Promise((l,u)=>{let c=e=>{if(!1===e)u(oT(4,{from:n,to:t}));else if(e instanceof Error)u(e);else"string"==typeof e||e&&"object"==typeof e?u(oT(2,{from:t,to:e})):(s&&r.enterCallbacks[i]===s&&"function"==typeof e&&s.push(e),l())},d=Promise.resolve(a(()=>e.call(r&&r.instances[i],t,n,c)));e.length<3&&(d=d.then(c)),d.catch(e=>u(e))})}function oZ(e,t,n,r,i=e=>e()){let a=[];for(let s of e)for(let e in s.components){let l=s.components[e];if("beforeRouteEnter"===t||s.instances[e])if(sZ(l)){let u=(l.__vccOpts||l)[t];u&&a.push(oJ(u,n,r,s,e,i))}else{let u=l();a.push(()=>u.then(a=>{var l;if(!a)throw Error(`Couldn't resolve component "${e}" at "${s.path}"`);let u=(l=a).__esModule||"Module"===l[Symbol.toStringTag]||l.default&&sZ(l.default)?a.default:a;s.mods[e]=a,s.components[e]=u;let c=(u.__vccOpts||u)[t];return c&&oJ(c,n,r,s,e,i)()}))}}return a}function o$(e){let t=rp(oH),n=rp(oW),r=iF(()=>{let n=tE(e.to);return t.resolve(n)}),i=iF(()=>{let{matched:e}=r.value,{length:t}=e,i=e[t-1],a=n.matched;if(!i||!a.length)return -1;let s=a.findIndex(of.bind(null,i));if(s>-1)return s;let l=oQ(e[t-2]);return t>1&&oQ(i)===l&&a[a.length-1].path!==l?a.findIndex(of.bind(null,e[t-2])):s}),a=iF(()=>i.value>-1&&function(e,t){for(let n in t){let r=t[n],i=e[n];if("string"==typeof r){if(r!==i)return!1}else if(!sX(i)||i.length!==r.length||r.some((e,t)=>e!==i[t]))return!1}return!0}(n.params,r.value.params)),s=iF(()=>i.value>-1&&i.value===n.matched.length-1&&oh(n.params,r.value.params));return{route:r,href:iF(()=>r.value.href),isActive:a,isExactActive:s,navigate:function(n={}){if(function(e){if(!e.metaKey&&!e.altKey&&!e.ctrlKey&&!e.shiftKey&&!e.defaultPrevented&&(void 0===e.button||0===e.button)){if(e.currentTarget&&e.currentTarget.getAttribute){let t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}(n)){let n=t[tE(e.replace)?"replace":"push"](tE(e.to)).catch(sQ);return e.viewTransition&&"undefined"!=typeof document&&"startViewTransition"in document&&document.startViewTransition(()=>n),n}return Promise.resolve()}}}let oY=ny({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:o$,setup(e,{slots:t}){let n=tc(o$(e)),{options:r}=rp(oH),i=iF(()=>({[oX(e.activeClass,r.linkActiveClass,"router-link-active")]:n.isActive,[oX(e.exactActiveClass,r.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{var r;let a=t.default&&(1===(r=t.default(n)).length?r[0]:r);return e.custom?a:ij("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:i.value},a)}}});function oQ(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}let oX=(e,t,n)=>null!=e?e:null!=t?t:n,o0=ny({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){let r=rp(oq),i=iF(()=>e.route||r.value),a=rp(oV,0),s=iF(()=>{let e,t=tE(a),{matched:n}=i.value;for(;(e=n[t])&&!e.components;)t++;return t}),l=iF(()=>i.value.matched[s.value]);rh(oV,iF(()=>s.value+1)),rh(oG,l),rh(oq,i);let u=tx();return rF(()=>[u.value,l.value,e.name],([e,t,n],[r,i,a])=>{t&&(t.instances[n]=e,i&&i!==t&&e&&e===r&&(t.leaveGuards.size||(t.leaveGuards=i.leaveGuards),t.updateGuards.size||(t.updateGuards=i.updateGuards))),!e||!t||i&&of(t,i)&&r||(t.enterCallbacks[n]||[]).forEach(t=>t(e))},{flush:"post"}),()=>{let r=i.value,a=e.name,s=l.value,c=s&&s.components[a];if(!c)return o1(n.default,{Component:c,route:r});let d=s.props[a],f=ij(c,s$({},d?!0===d?r.params:"function"==typeof d?d(r):d:null,t,{onVnodeUnmounted:e=>{e.component.isUnmounted&&(s.instances[a]=null)},ref:u}));return o1(n.default,{Component:f,route:r})||f}}});function o1(e,t){if(!e)return null;let n=e(t);return 1===n.length?n[0]:n}function o2(e){let t=[],{record:n}=e;null!=n.name&&t.push({label:String(n.name),textColor:0,backgroundColor:2282478}),n.aliasOf&&t.push({label:"alias",textColor:0,backgroundColor:0xfb923c}),e.__vd_match&&t.push({label:"matches",textColor:0,backgroundColor:0xec4899}),e.__vd_exactActive&&t.push({label:"exact",textColor:0,backgroundColor:8702998}),e.__vd_active&&t.push({label:"active",textColor:0,backgroundColor:2450411}),n.redirect&&t.push({label:"string"==typeof n.redirect?`redirect: ${n.redirect}`:"redirects",textColor:0xffffff,backgroundColor:6710886});let r=n.__vd_id;return null==r&&(n.__vd_id=r=String(o5++)),{id:r,label:n.path,tags:t,children:e.children.map(o2)}}let o5=0;function o3(e){e.__vd_match=!1,e.children.forEach(o3)}let o6={class:"text-sm pos-fixed bottom-0 left-0 right-0 md:py-2 b-t-solid b b-gray-7 md:b-r-solid md:top-0 md:right-auto flex justify-around md:flex-col md:justify-left dark:bg-dark-7 z-10"},o4={class:"h-full scrolly md:px-3"},o8=ny({__name:"App",setup(e){let t=[{icon:"i-ri-home-smile-line",link:"/"},{icon:"i-ri-apps-2-line",link:"/category"},{icon:"i-ri-heart-line",link:"/follow"},{icon:"i-ri-search-line",link:"/search"},{icon:"i-ri-user-smile-line",link:"/user"}];nz(async()=>{document.querySelector("main").style.height=`calc(${window.innerHeight}px - 3.5rem)`});let n=rp(oW);return nz(()=>{/^http(s)?:\/\/lemonlive(25)?.(deno|pages).dev/.test(n.fullPath)||window.close()}),rF(n,()=>{let e=n.params.siteid;if(void 0==e)return;let t=sy.findIndex(t=>t==e);-1!=t&&(sD.value=t)},void 0),rN(()=>{document.querySelectorAll(".v-toast").forEach(e=>{e.style.left=sU?"70px":"0"})}),(e,n)=>{let r=nY("router-link"),i=nY("router-view");return r9(),ii(r2,null,[t5(ic("div",o6,[(r9(),ii(r2,null,n2(t,t=>id(r,{to:t.link,class:ep(["hover:text-amber rounded-2 py-2 px-4 m-2",{"text-amber":e.$route.path==t.link}])},{default:t2(()=>[ic("div",{class:ep(t.icon)},null,2)]),_:2},1032,["to","class"])),64))],512),[[at,tE(sU)]]),ic("main",{class:ep(["md:!h-100vh mx-2 md:mx-0 pt-2 box-border",{"md:ml-17.5":tE(sU),"!h-100vh":!tE(sU)}])},[ic("div",o4,[id(i,null,{default:t2(e=>{let{Component:t}=e;return[(r9(),ia(nD,{exclude:["play"]},[(r9(),ia(nX(t)))],1024))]}),_:1})])],2)],64)}}}),o9=e=>{let t=tx(e);return[t,e=>t.value=e]},o7=/scroll|auto|overlay/i,le={key:0,class:"text-center"},lt={key:1,class:"text-center"},ln=ny({__name:"list",props:{finshedText:{default:"没有更多了"},errorText:{default:"加载失败,点击重新加载"},immediate:{type:Boolean,default:!0},offset:{default:50}},emits:["load","refresh"],setup(e,t){let n,{emit:r}=t,i=tx(0),[a,s]=o9("normal"),l=tx(),u=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document.body,n=tx();return nz(()=>{e.value&&(n.value=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document.body,r=e;for(;r&&r!==n&&"HTML"!==(t=r).tagName&&"BODY"!==t.tagName&&1===t.nodeType;){let{overflowY:e}=window.getComputedStyle(r);if(o7.test(e))return r;r=r.parentNode}return n}(e.value,t))}),n}(l),c=()=>{i.value=u.value.scrollTop,"normal"==a.value&&u.value.scrollHeight-u.value.clientHeight-u.value.scrollTop<e.offset&&f()};nz(()=>{e.immediate&&f(),u.value.addEventListener("scroll",c,{passive:!0})}),nU(()=>{u.value.scrollTop=i.value,u.value.addEventListener("scroll",c)});let d=()=>{u.value.removeEventListener("scroll",c)};nL(d),nH(d);let f=()=>{s("loading"),r("load",s),clearTimeout(n),n=setTimeout(()=>{si(u.value)||r("load",s)},2e3)};return(t,n)=>(r9(),ii("div",{ref_key:"root",ref:l,class:"h-full select-none"},[function(e,t,n={},r,i){if(tX.ce||tX.parent&&nC(tX.parent)&&tX.parent.ce)return"default"!==t&&(n.name=t),r9(),ia(r2,null,[id("slot",n,void 0)],64);let a=e[t];a&&a._c&&(a._d=!1),r9();let s=a&&function e(t){return t.some(t=>!is(t)||t.type!==r3&&(t.type!==r2||!!e(t.children)))?t:null}(a(n)),l=n.key||s&&s.key,u=ia(r2,{key:(l&&!G(l)?l:`_${t}`)+""},s||(r?r():[]),s&&1===e._?64:-2);return u.scopeId&&(u.slotScopeIds=[u.scopeId+"-s"]),a&&a._c&&(a._d=!0),u}(t.$slots,"default"),"loading"==tE(a)?(r9(),ii("div",le,"加载中...")):"finshed"==tE(a)?(r9(),ii("div",lt,eg(e.finshedText),1)):"loaderror"==tE(a)?(r9(),ii("div",{key:2,class:"text-center cursor-pointer",onClick:f},eg(e.errorText),1)):im("",!0)],512))}}),lr={key:0,ref:"root",class:"grid gap-4 p-2 justify-evenly cursor-pointer select-none grid-cols-2 md:grid-cols-3 xl:grid-cols-4 2xl:grid-cols-5"},li={class:"room-item-info shadow rounded-2 b-2px b-solid b-transparent pos-relative overflow-hidden"},la={class:"pos-relative text-fuchsia-5 rounded-t-2 w-full aspect-video"},ls=["src"],lo={class:"pos-absolute bottom-0 right-0 px-2 py-1 rounded-tl-2 bg-dark-6"},ll={class:"line-height-none pos-absolute top-0 right-0 px-1 py-1 rounded-tr-1 rounded-bl-2 bg-dark-6"},lu={key:0,class:"rounded-2 text-white pos-absolute text-8 top-0 bottom-0 left-0 right-0 flex justify-center items-center bg-gray-7 bg-op-80"},lc={class:"px-2 text-truncate leading-normal"},ld={class:"px-2 pb-2 mt-1 flex items-center justify-between"},lf={class:"flex items-center grow"},lh=["src"],lp={class:"text-truncate mx-1 w-2 grow"},lv=["onClick"],lm={key:1,class:"px-2 text-truncate leading-normal pb-2"},lg=ny({__name:"rooms",props:{list:{},remove:{type:Boolean}},setup:e=>(e,t)=>{let n=nY("router-link");return e.list.value.length>0?(r9(),ii("div",lr,[(r9(!0),ii(r2,null,n2(e.list.value,r=>(r9(),ia(n,{to:`/${r.siteId}/play/${r.roomId}`,key:`${r.siteId}-${r.roomId}`,class:"room-item"},{default:t2(()=>[ic("div",li,[ic("div",la,[ic("img",{loading:"lazy",src:r.cover,class:"mx-auto h-full rounded-2 select-none block"},null,8,ls),ic("div",lo,eg(r.category),1),ic("div",ll,[t[0]||(t[0]=ic("div",{class:"i-mdi-fire"},null,-1)),ic("span",null,eg(r.online),1)]),r.status?im("",!0):(r9(),ii("div",lu," 未开播 "))]),ic("div",lc,eg(r.title),1),e.remove?(r9(),ii(r2,{key:0},[ic("div",ld,[ic("div",lf,[ic("img",{src:r.avatar,alt:"",class:"w-6 h-6 rounded-4"},null,8,lh),ic("div",lp,eg(r.nickname),1)]),ic("div",null,eg(tE(sm)[r.siteId]),1)]),ic("div",{class:"pos-absolute z-1 left-0 top-0 p-2 text-green-5 hover:text-rose-5",onClick:aC(e=>tE(sK)(r),["prevent"])},t[1]||(t[1]=[ic("div",{class:"w-8 h-8 i-mdi-heart-off-outline"},null,-1)]),8,lv)],64)):(r9(),ii("div",lm,eg(r.nickname),1))])]),_:2},1032,["to"]))),128))],512)):im("",!0)}}),ly={class:"h-full"},l_={class:"py-1 px-2 text-lg text-center relative"},lb={class:"hover:text-amber"},lw={key:0,class:"h-[calc(100%-3.25rem)] scrolly"},lx=ny({__name:"categoryRooms",setup(e){let t=rp(oW),n=tx(""),r=tx(),i={list:tx([]),page:1,hasMore:!0},a=e=>{let{site:a,id:s}=t.meta;sd(a.id,"getCategoryRooms",{id:s,pid:r.value,page:i.page}).then(t=>{if(i.list.value=i.list.value.concat(t.list),i.hasMore=t.hasMore,sI[a.id]||(sI[a.id]=t.cookie),!t.hasMore)return e("finshed");i.page++,e("normal")},t=>{n.value=t,e("loaderror")})},s=tx(!1),l=()=>{document.querySelector("#goTop").click(),s.value=!0;let{site:e,id:a}=t.meta;sd(e.id,"getCategoryRooms",{id:a,pid:r.value,page:i.page}).then(t=>{i.list.value=t.list,i.hasMore=t.hasMore,i.page++,sI[e.id]||(sI[e.id]=t.cookie)},e=>{n.value=e}).finally(()=>s.value=!1)},u=t.fullPath;return sS(t.meta.site,t.meta.id).then(e=>{n.value=(null==e?void 0:e.name)||null,r.value=null==e?void 0:e.pid}),nU(function(){u!=t.fullPath&&(u=t.fullPath,sS(t.meta.site,t.meta.id).then(e=>{n.value=(null==e?void 0:e.name)||null,r.value=null==e?void 0:e.pid}),i.list.value=[],i.page=1,i.hasMore=!0)}),(e,r)=>{var c;return r9(),ii("div",ly,[ic("div",l_,[ic("div",{onClick:r[0]||(r[0]=function(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.$router.back&&e.$router.back(...n)}),class:"i-ri-arrow-left-line hover:text-amber absolute left-2"}),ic("div",{onClick:l,class:ep(["i-ri-refresh-line hover:text-amber absolute right-4 md:right-unset md:left-12",{"animate-spin":tE(s)}])},null,2),ic("span",lb,eg(`${null==(c=tE(t).meta.site)?void 0:c.name} ${null==tE(n)?"分区不存在":""==tE(n)?"加载中":tE(n)}`),1)]),tE(n)?(r9(),ii("div",lw,[(r9(),ia(ln,{key:tE(u),onLoad:a},{default:t2(()=>[id(lg,{list:i.list},null,8,["list"])]),_:1}))])):im("",!0)])}}}),lk=Symbol("tabs"),lS=(e,t)=>{let n=tc([]);return rh(e,Object.assign({link:e=>{e.proxy&&n.push(e.proxy)},unlink:e=>{let t=n.indexOf(e.proxy);n.splice(t,1)},children:n},t)),n},lE=e=>{let t=rp(e);if(void 0==t)return{parent:t,index:tx(-1)};let n=iS(),{link:r,unlink:i,children:a}=t;r(n),nW(()=>i(n));let s=iF(()=>a.indexOf(n.proxy));return{parent:t,children:a,index:s}},lT={class:"h-full box-border"},lA={class:"w-full box-border text-sm sm:text-base"},lO=["onClick"],lC={class:"h-[calc(100%-2rem)] scrolly box-border pt-1"},lI=ny({__name:"tabs",props:n7({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:n7(["tabClick"],["update:active"]),setup(e,t){let{emit:n}=t,r=rG(e,"active"),i=e=>{r.value=e,n("tabClick",e)},a=lS(lk,{active:r,props:e}),s=iF(()=>sn(a,e=>e.title)),l=n8();return(t,n)=>{let u=nY("router-link");return r9(),ii("div",lT,[ic("div",lA,[ic("div",{class:ep(["flex p1 sm:gap-1 text-center h-8 box-border lg:justify-center scrollx",[tE(a).length>5||t.grow?"":t.justify]])},[e.link?(r9(!0),ii(r2,{key:0},n2(tE(s),(e,n)=>(r9(),ia(u,{class:ep(["px-1 sm:px-2 box-border shrink-0 rounded py-1 line-height-none text-centercursor-pointer hover:text-amber cursor-pointer",{"text-amber":r.value==n,grow:t.grow}]),to:tE(a)[n].href},{default:t2(()=>[iv(eg(e),1)]),_:2},1032,["class","to"]))),256)):(r9(!0),ii(r2,{key:1},n2(tE(s),(e,n)=>(r9(),ii("a",{class:ep(["px-1 sm:px-2 box-border shrink-0 rounded py-1 line-height-none text-centercursor-pointer hover:text-amber cursor-pointer",{"text-amber":r.value==n,grow:t.grow}]),onClick:e=>i(n)},eg(e),11,lO))),256))],2)]),ic("div",lC,[(r9(),ia(nX(l.default)))])])}}}),lD=Symbol("swipe"),lR={class:"w-full h-full shrink-0 pos-relative"},lU=ny({__name:"swipeItem",emits:["inited"],setup(e,t){let{emit:n}=t,r=tx(!1),{parent:i,children:a,index:s}=lE(lD),l=n8(),u=iF(()=>(null==i?void 0:i.active.value)==s.value?(r.value||(r.value=!0,n("inited",s.value)),!0):s.value==(0==i.active.value?a.length-1:i.active.value-1)||s.value==(i.active.value==a.length-1?0:i.active.value+1)),c=iF(()=>u.value||r.value||!(null==i?void 0:i.props.lazy)?l.default:null);return(e,t)=>t5((r9(),ii("div",lR,[(r9(),ia(nX(tE(c))))],512)),[[at,tE(u)]])}}),lL={class:"scrolly h-full w-full shrink-0"},lP=ny({__name:"tab",props:{title:{},href:{}},emits:["inited"],setup(e,t){let{expose:n,emit:r}=t,i=tx(!1),a=n8(),{parent:s,index:l,children:u}=lE(lk),c=iF(()=>(null==s?void 0:s.active.value)==l.value?(i.value||(i.value=!0,r("inited",l.value)),!0):(null==s?void 0:s.props.swipeable)&&(l.value==(0==s.active.value?u.length-1:s.active.value-1)||l.value==(s.active.value==u.length-1?0:s.active.value+1))),d=iF(()=>c.value||(null==s?void 0:s.props.swipeable)||i.value||!(null==s?void 0:s.props.lazy)?a.default:null);return n({title:e.title}),(e,t)=>{var n,r;return t5((r9(),ii("div",lL,[(null==(n=tE(s))?void 0:n.props.swipeable)?(r9(),ia(lU,{key:0},{default:t2(()=>[(r9(),ia(nX(tE(d))))]),_:1})):(r9(),ia(nX(tE(d)),{key:1}))],512)),[[at,tE(c)||(null==(r=tE(s))?void 0:r.props.swipeable)]])}}}),lB={key:0,class:"text-center"},lM={class:"pb-2 grid gap-4 px-4 md:px-2 grid-cols-4 sm:grid-cols-6 md:grid-cols-8 lg:grid-cols-10 xl:grid-cols-15 2xl:grid-cols-18"},lN=["src"],lF={class:"w-full text-truncate text-xs md:text-sm text-center"},lj=ny({__name:"category",setup(e){let t=iF(()=>sg[sD.value].id),n=tx(),r=e=>{sg[e].categories.value.length||(n.value="加载中...",sd(t.value,"getCategories").then(t=>{n.value=null,sg[e].categories.value=t},e=>n.value=e))};return(e,t)=>{let i=nY("router-link");return r9(),ia(lI,{active:tE(sD),"onUpdate:active":t[0]||(t[0]=e=>tw(sD)?sD.value=e:null),link:!0,class:"pt-1"},{default:t2(()=>[(r9(!0),ii(r2,null,n2(tE(sg),e=>(r9(),ia(lP,{title:e.name,href:`/${e.id}/category`,onInited:r,key:e.id},{default:t2(()=>[tE(n)?(r9(),ii("div",lB,eg(tE(n)),1)):(r9(),ia(lI,{key:1,active:e.categoryActive.value,"onUpdate:active":t=>e.categoryActive.value=t},{default:t2(()=>[(r9(!0),ii(r2,null,n2(e.categories.value,t=>(r9(),ia(lP,{title:t.name,key:t.id},{default:t2(()=>[ic("div",lM,[(r9(!0),ii(r2,null,n2(t.list,t=>(r9(),ia(i,{to:`/${e.id}/category/${t.cid}`,class:"cursor-pointer"},{default:t2(()=>[ic("img",{loading:"lazy",src:t.pic,class:"w-full aspect-ratio-square rounded"},null,8,lN),ic("div",lF,eg(t.name),1)]),_:2},1032,["to"]))),256))])]),_:2},1032,["title"]))),128))]),_:2},1032,["active","onUpdate:active"]))]),_:2},1032,["title","href"]))),128))]),_:1},8,["active"])}}}),lz={class:"text-center py-1"},lG={class:"w-60% max-w-md pos-relative inline-block"},lV={class:"h-[calc(100%-3rem)]"},lH={key:1},lW={key:1},lq=ny({__name:"search",setup(e){let t=tx(""),n=iF(()=>sg[sD.value]),r=tx(),i=()=>{if(!t.value)return Promise.resolve();let e=n.value.search;e.list.value=[],e.page=1,e.hasMore=!0,r.value="搜索中...";let i=n.value.id;return sd(i,"searchRooms",{page:e.page,kw:t.value}).then(t=>{e.list.value=t.list,e.hasMore=t.hasMore,e.page+=1,r.value="finished",sI[i]||(sI[i]=t.cookie)},e=>r.value=e)},a=e=>{let r=n.value.search,i=n.value.id;e("loading"),sd(i,"searchRooms",{page:r.page,kw:t.value}).then(t=>{if(r.list.value=r.list.value.concat(t.list),r.hasMore=t.hasMore,sI[i]||(sI[i]=t.cookie),!r.hasMore)return e("finshed");r.page+=1,e("normal")},t=>{e("loaderror")})},s=e=>{l.push(`/${sy[e]}/search`),u()||1==sg[e].search.page&&i()},l=rp(oH),u=()=>{if(t.value)return!!/^[\d]*$/.test(t.value)&&(l.push(`/play/${n.value.id}/${t.value}`),!0)},c=()=>{u()||(sg.forEach(e=>e.search.page=1),i())};return(e,n)=>(r9(),ii(r2,null,[ic("div",lz,[ic("div",lG,[t5(ic("input",{class:"md:text-4 box-border w-full py-2.5 pl-3 pr-9 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-0",type:"text","onUpdate:modelValue":n[0]||(n[0]=e=>tw(t)?t.value=e:null),onKeydown:aD(c,["enter"]),placeholder:"请输入房间号或关键字"},null,544),[[aT,tE(t),void 0,{trim:!0}]]),ic("div",{class:"i-ri-search-line top-50% absolute right-3",onClick:c,style:{transform:"translateY(-50%)"}})])]),ic("div",lV,[id(lI,{active:tE(sD),"onUpdate:active":n[1]||(n[1]=e=>tw(sD)?sD.value=e:null),onTabClick:s},{default:t2(()=>[(r9(!0),ii(r2,null,n2(tE(sg),e=>(r9(),ia(lP,{title:e.name,key:e.id},{default:t2(()=>["finished"==tE(r)?(r9(),ii(r2,{key:0},[e.search.list.value.length?(r9(),ia(ln,{key:0,onLoad:a},{default:t2(()=>[id(lg,{list:e.search.list},null,8,["list"])]),_:2},1024)):(r9(),ii("div",lH," 什么也没有找到 "))],64)):(r9(),ii("div",lW,eg(tE(r)),1))]),_:2},1032,["title"]))),128))]),_:1},8,["active"])])],64))}}),lK={class:"flex justify-center items-center"},lJ={class:"h-[calc(100%-3rem)]"},lZ=ny({__name:"follow",setup(e){let t=tx(0),n=tx(!1),r=()=>{var e;if(n.value)return;let r=t.value;n.value=!0,0==r?Promise.all(sn(sg,sf)).finally(i):null==(e=sf(sg[r-1]))||e.finally(i)},i=()=>setTimeout(()=>n.value=!1,300);rF(sz,()=>{!0!=sz.value&&r()},{immediate:!0});let a=e=>e("finshed");return(e,i)=>(r9(),ii(r2,null,[ic("div",lK,[i[1]||(i[1]=ic("div",null,"我的关注",-1)),ic("div",{onClick:r,class:ep(["rounded-6 mx-4 hover:text-amber i-ri-refresh-line",{"animate-spin":tE(n)}])},null,2)]),ic("div",lJ,[id(lI,{active:tE(t),"onUpdate:active":i[0]||(i[0]=e=>tw(t)?t.value=e:null)},{default:t2(()=>[(r9(!0),ii(r2,null,n2(tE(sL),e=>(r9(),ia(lP,{title:e.name},{default:t2(()=>[id(ln,{onLoad:a,"finshed-text":""},{default:t2(()=>[id(lg,{list:e.list,remove:!0},null,8,["list"])]),_:2},1024)]),_:2},1032,["title"]))),256))]),_:1},8,["active"])])],64))}}),l$=ny({__name:"index",setup(e){let t=iF(()=>sg[sD.value].id),n=e=>{let n=sg[sD.value].recommend;sd(t.value,"getRecommendRooms",{page:n.page}).then(r=>{if(n.list.value=n.list.value.concat(r.list),n.hasMore=r.hasMore,sI[t.value]||(sI[t.value]=r.cookie),!n.hasMore)return e("finshed");n.page++,e("normal")},()=>e("loaderror"))};return(e,t)=>(r9(),ia(lI,{active:tE(sD),"onUpdate:active":t[0]||(t[0]=e=>tw(sD)?sD.value=e:null),link:!0,class:"pt-1"},{default:t2(()=>[(r9(!0),ii(r2,null,n2(tE(sg),e=>(r9(),ia(lP,{href:`/${e.id}`,key:e.id,title:e.name,class:"pos-relative"},{default:t2(()=>[id(ln,{onLoad:n,class:"h-full"},{default:t2(()=>[id(lg,{list:e.recommend.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["href","title"]))),128))]),_:1},8,["active"]))}}),lY=ny({__name:"switch",props:{value:{type:Boolean,required:!0},valueModifiers:{}},emits:["update:value"],setup(e){let t=rG(e,"value");return(e,n)=>(r9(),ii("div",{onClick:n[0]||(n[0]=()=>t.value=!t.value),class:ep(["pos-relative w-12 inline-block cursor-pointer rounded-6 h-6",[t.value?"bg-amber":"bg-gray-4"]]),style:{transition:"background-color .3s"}},[ic("div",{class:"w-6 h-full rounded-6 bg-white",style:ec([{transition:"transform .3s"},t.value?"transform:translateX(1.5rem)":""])},null,4)],2))}}),lQ={class:"rounded-4 flex bg-gray-7 w-min p-2 py-1 gap-2"},lX=ny({__name:"stepper",props:n7({max:{},min:{},step:{}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(e){let t=rG(e,"value"),n=()=>t.value=Math.min(t.value+e.step,e.max),r=()=>t.value=Math.max(t.value-e.step,e.min);return(e,i)=>(r9(),ii("div",lQ,[ic("div",{class:"i-ri-subtract-fill",onClick:r}),ic("div",null,eg(t.value),1),ic("div",{class:"i-ri-add-fill",onClick:n})]))}}),l0=function(){try{return document.createEvent("TouchEvent"),!0}catch(e){return!1}}(),l1=e=>l0?void 0==e.touches?e:e.touches[0]||e.changedTouches[0]:e,l2=ny({__name:"slider",props:n7({max:{default:100},min:{default:0},width:{default:30},height:{default:100}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(e){let t,n=rG(e,"value"),r=tx(),i=e.width<e.height,a=e=>{e.stopPropagation(),u(e),document.addEventListener("mousemove",u,!0),document.addEventListener("mouseup",c,!0)},s=iF(()=>(n.value-e.min)/(e.max-e.min)*100),l=iF(()=>{let e=100-s.value,t=`top:${e}%`,n=`left:${e}%`;return i?{loaded:t,indicator:t}:{loaded:`${n};transform:translateX(-100%)`,indicator:n}}),u=r=>{r.stopPropagation(),r=l1(r);let a=100-(Math.min(i?t.height:t.width,Math.max(0,i?r.clientY-t.y:r.clientX-t.x))/(i?t.height:t.width)*100|0);n.value=((e.max-e.min)*a|0)/100+e.min|0},c=e=>{e.stopPropagation(),document.removeEventListener("mousemove",u,!0),document.removeEventListener("mouseup",c,!0)};return nz(()=>{t=r.value.getBoundingClientRect(),r.value.addEventListener("mousedown",a,!0)}),nH(()=>{r.value.removeEventListener("mousedown",a,!0)}),(t,n)=>(r9(),ii("div",{class:ep(["cursor-pointer flex justify-center",i?" py-4 ":"px-4"]),style:ec({width:`${e.width}px`,height:`${e.height}px`})},[ic("div",{ref_key:"root",ref:r,onClick:u,class:"w-full h-full pos-relative flex justify-center items-center"},[ic("div",{class:ep(["bg-gray pos-relative overflow-hidden",i?"h-full w-2px":"w-full h-2px"])},[ic("div",{class:"w-full bg-amber h-full pos-absolute",style:ec(tE(l).loaded)},null,4)],2),ic("div",{class:ep(["pos-absolute w-12px h-12px bg-amber rounded-2",i?"-mt-6px":"-ml-6px"]),style:ec(tE(l).indicator)},null,6)],512)],6))}}),l5={key:0,class:"z-1 fixed top-0 bottom-0 left-0 right-0 bg-transparent","data-index":"-1"},l3={class:"p-1 hover:text-amber","data-index":"-1"},l6={class:"left-50% text-center z-1 pos-absolute top-0 w-max",style:{transform:"translate3d(-50%,-100%,0)"}},l4=["data-index"],l8=ny({__name:"select",props:n7(["list"],{active:{required:!0},activeModifiers:{}}),emits:["update:active"],setup(e){let t=rG(e,"active"),n=tx(!1),r=e=>{let r=e.target.dataset.index;r&&("-1"!=r&&(t.value=parseInt(r)),n.value=!n.value)};return(i,a)=>(r9(),ii("div",{onClick:r,class:"inline-block pos-relative cursor-pointer text-center"},[tE(n)?(r9(),ii("div",l5)):im("",!0),ic("div",l3,eg(e.list[t.value]),1),t5(ic("div",l6,[(r9(!0),ii(r2,null,n2(e.list,(e,n)=>(r9(),ii("div",{"data-index":n,class:ep([{"text-amber":n==t.value},"p-1 hover:text-amber"])},eg(e),11,l4))),256))],512),[[at,tE(n)]])]))}});var l9=Object.create,l7=Object.defineProperty,ue=Object.getOwnPropertyDescriptor,ut=Object.getOwnPropertyNames,un=Object.getPrototypeOf,ur=Object.prototype.hasOwnProperty,ui=(e,t,n,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of ut(t))ur.call(e,i)||i===n||l7(e,i,{get:()=>t[i],enumerable:!(r=ue(t,i))||r.enumerable});return e},ua=(e,t,n)=>(n=null!=e?l9(un(e)):{},ui(!t&&e&&e.__esModule?n:l7(n,"default",{value:e,enumerable:!0}),e)),us=((e,t)=>function(){return t||(0,e[ut(e)[0]])((t={exports:{}}).exports,t),t.exports})({"node_modules/eventemitter3/index.js"(e,t){var n=Object.prototype.hasOwnProperty,r="~";function i(){}function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function s(e,t,n,i,s){if("function"!=typeof n)throw TypeError("The listener must be a function");var l=new a(n,i||e,s),u=r?r+t:t;return e._events[u]?e._events[u].fn?e._events[u]=[e._events[u],l]:e._events[u].push(l):(e._events[u]=l,e._eventsCount++),e}function l(e,t){0==--e._eventsCount?e._events=new i:delete e._events[t]}function u(){this._events=new i,this._eventsCount=0}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1)),u.prototype.eventNames=function(){var e,t,i=[];if(0===this._eventsCount)return i;for(t in e=this._events)n.call(e,t)&&i.push(r?t.slice(1):t);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(e)):i},u.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,s=Array(a);i<a;i++)s[i]=n[i].fn;return s},u.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},u.prototype.emit=function(e,t,n,i,a,s){var l=r?r+e:e;if(!this._events[l])return!1;var u,c,d=this._events[l],f=arguments.length;if(d.fn){switch(d.once&&this.removeListener(e,d.fn,void 0,!0),f){case 1:return d.fn.call(d.context),!0;case 2:return d.fn.call(d.context,t),!0;case 3:return d.fn.call(d.context,t,n),!0;case 4:return d.fn.call(d.context,t,n,i),!0;case 5:return d.fn.call(d.context,t,n,i,a),!0;case 6:return d.fn.call(d.context,t,n,i,a,s),!0}for(c=1,u=Array(f-1);c<f;c++)u[c-1]=arguments[c];d.fn.apply(d.context,u)}else{var h,p=d.length;for(c=0;c<p;c++)switch(d[c].once&&this.removeListener(e,d[c].fn,void 0,!0),f){case 1:d[c].fn.call(d[c].context);break;case 2:d[c].fn.call(d[c].context,t);break;case 3:d[c].fn.call(d[c].context,t,n);break;case 4:d[c].fn.call(d[c].context,t,n,i);break;default:if(!u)for(h=1,u=Array(f-1);h<f;h++)u[h-1]=arguments[h];d[c].fn.apply(d[c].context,u)}}return!0},u.prototype.on=function(e,t,n){return s(this,e,t,n,!1)},u.prototype.once=function(e,t,n){return s(this,e,t,n,!0)},u.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return l(this,a),this;var s=this._events[a];if(s.fn)s.fn!==t||i&&!s.once||n&&s.context!==n||l(this,a);else{for(var u=0,c=[],d=s.length;u<d;u++)(s[u].fn!==t||i&&!s[u].once||n&&s[u].context!==n)&&c.push(s[u]);c.length?this._events[a]=1===c.length?c[0]:c:l(this,a)}return this},u.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&l(this,t)):(this._events=new i,this._eventsCount=0),this},u.prototype.off=u.prototype.removeListener,u.prototype.addListener=u.prototype.on,u.prefixed=r,u.EventEmitter=u,void 0!==t&&(t.exports=u)}});function uo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function ul(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?uo(Object(n),!0).forEach(function(t){uv(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):uo(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function uu(){uu=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",s=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function u(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,n){return e[t]=n}}function c(e,t,n,i){var a,s,l,u,c=Object.create((t&&t.prototype instanceof h?t:h).prototype);return r(c,"_invoke",{value:(a=e,s=n,l=new E(i||[]),u="suspendedStart",function(e,t){if("executing"===u)throw Error("Generator is already running");if("completed"===u){if("throw"===e)throw t;return A()}for(l.method=e,l.arg=t;;){var n=l.delegate;if(n){var r=function e(t,n){var r=n.method,i=t.iterator[r];if(void 0===i)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=void 0,e(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=TypeError("The iterator does not provide a '"+r+"' method")),f;var a=d(i,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,f;var s=a.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=void 0),n.delegate=null,f):s:(n.method="throw",n.arg=TypeError("iterator result is not an object"),n.delegate=null,f)}(n,l);if(r){if(r===f)continue;return r}}if("next"===l.method)l.sent=l._sent=l.arg;else if("throw"===l.method){if("suspendedStart"===u)throw u="completed",l.arg;l.dispatchException(l.arg)}else"return"===l.method&&l.abrupt("return",l.arg);u="executing";var i=d(a,s,l);if("normal"===i.type){if(u=l.done?"completed":"suspendedYield",i.arg===f)continue;return{value:i.arg,done:l.done}}"throw"===i.type&&(u="completed",l.method="throw",l.arg=i.arg)}})}),c}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var f={};function h(){}function p(){}function m(){}var g={};u(g,a,function(){return this});var y=Object.getPrototypeOf,_=y&&y(y(T([])));_&&_!==t&&n.call(_,a)&&(g=_);var b=m.prototype=h.prototype=Object.create(g);function w(e){["next","throw","return"].forEach(function(t){u(e,t,function(e){return this._invoke(t,e)})})}function x(e,t){var i;r(this,"_invoke",{value:function(r,a){function s(){return new t(function(i,s){!function r(i,a,s,l){var u=d(e[i],e,a);if("throw"!==u.type){var c=u.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then(function(e){r("next",e,s,l)},function(e){r("throw",e,s,l)}):t.resolve(f).then(function(e){c.value=e,s(c)},function(e){return r("throw",e,s,l)})}l(u.arg)}(r,a,i,s)})}return i=i?i.then(s,s):s()}})}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function S(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function T(e){if(e){var t=e[a];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:A}}function A(){return{value:void 0,done:!0}}return p.prototype=m,r(b,"constructor",{value:m,configurable:!0}),r(m,"constructor",{value:p,configurable:!0}),p.displayName=u(m,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,u(e,l,"GeneratorFunction")),e.prototype=Object.create(b),e},e.awrap=function(e){return{__await:e}},w(x.prototype),u(x.prototype,s,function(){return this}),e.AsyncIterator=x,e.async=function(t,n,r,i,a){void 0===a&&(a=Promise);var s=new x(c(t,n,r,i),a);return e.isGeneratorFunction(n)?s:s.next().then(function(e){return e.done?e.value:s.next()})},w(b),u(b,l,"Generator"),u(b,a,function(){return this}),u(b,"toString",function(){return"[object Generator]"}),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=T,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return s.type="throw",s.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return r("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),u=n.call(a,"finallyLoc");if(l&&u){if(this.prev<a.catchLoc)return r(a.catchLoc,!0);if(this.prev<a.finallyLoc)return r(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return r(a.catchLoc,!0)}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return r(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var s=a?a.completion:{};return s.type=e,s.arg=t,a?(this.method="next",this.next=a.finallyLoc,f):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),S(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;S(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:T(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}function uc(e,t,n,r,i,a,s){try{var l=e[a](s),u=l.value}catch(e){n(e);return}l.done?t(u):Promise.resolve(u).then(r,i)}function ud(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var a=e.apply(t,n);function s(e){uc(a,r,i,s,l,"next",e)}function l(e){uc(a,r,i,s,l,"throw",e)}s(void 0)})}}function uf(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function uh(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,u_(r.key),r)}}function up(e,t,n){return t&&uh(e.prototype,t),n&&uh(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function uv(e,t,n){return(t=u_(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function um(e){return(um=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function ug(e,t){return(ug=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function uy(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function u_(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}function ub(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function uw(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ub(Object(n),!0).forEach(function(t){uC(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ub(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ux(){ux=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",s=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function u(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(e){u=function(e,t,n){return e[t]=n}}function c(e,t,n,i){var a,s,l,u,c=Object.create((t&&t.prototype instanceof h?t:h).prototype);return r(c,"_invoke",{value:(a=e,s=n,l=new E(i||[]),u="suspendedStart",function(e,t){if("executing"===u)throw Error("Generator is already running");if("completed"===u){if("throw"===e)throw t;return A()}for(l.method=e,l.arg=t;;){var n=l.delegate;if(n){var r=function e(t,n){var r=n.method,i=t.iterator[r];if(void 0===i)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=void 0,e(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=TypeError("The iterator does not provide a '"+r+"' method")),f;var a=d(i,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,f;var s=a.arg;return s?s.done?(n[t.resultName]=s.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=void 0),n.delegate=null,f):s:(n.method="throw",n.arg=TypeError("iterator result is not an object"),n.delegate=null,f)}(n,l);if(r){if(r===f)continue;return r}}if("next"===l.method)l.sent=l._sent=l.arg;else if("throw"===l.method){if("suspendedStart"===u)throw u="completed",l.arg;l.dispatchException(l.arg)}else"return"===l.method&&l.abrupt("return",l.arg);u="executing";var i=d(a,s,l);if("normal"===i.type){if(u=l.done?"completed":"suspendedYield",i.arg===f)continue;return{value:i.arg,done:l.done}}"throw"===i.type&&(u="completed",l.method="throw",l.arg=i.arg)}})}),c}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=c;var f={};function h(){}function p(){}function m(){}var g={};u(g,a,function(){return this});var y=Object.getPrototypeOf,_=y&&y(y(T([])));_&&_!==t&&n.call(_,a)&&(g=_);var b=m.prototype=h.prototype=Object.create(g);function w(e){["next","throw","return"].forEach(function(t){u(e,t,function(e){return this._invoke(t,e)})})}function x(e,t){var i;r(this,"_invoke",{value:function(r,a){function s(){return new t(function(i,s){!function r(i,a,s,l){var u=d(e[i],e,a);if("throw"!==u.type){var c=u.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then(function(e){r("next",e,s,l)},function(e){r("throw",e,s,l)}):t.resolve(f).then(function(e){c.value=e,s(c)},function(e){return r("throw",e,s,l)})}l(u.arg)}(r,a,i,s)})}return i=i?i.then(s,s):s()}})}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function S(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function T(e){if(e){var t=e[a];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:A}}function A(){return{value:void 0,done:!0}}return p.prototype=m,r(b,"constructor",{value:m,configurable:!0}),r(m,"constructor",{value:p,configurable:!0}),p.displayName=u(m,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,u(e,l,"GeneratorFunction")),e.prototype=Object.create(b),e},e.awrap=function(e){return{__await:e}},w(x.prototype),u(x.prototype,s,function(){return this}),e.AsyncIterator=x,e.async=function(t,n,r,i,a){void 0===a&&(a=Promise);var s=new x(c(t,n,r,i),a);return e.isGeneratorFunction(n)?s:s.next().then(function(e){return e.done?e.value:s.next()})},w(b),u(b,l,"Generator"),u(b,a,function(){return this}),u(b,"toString",function(){return"[object Generator]"}),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=T,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return s.type="throw",s.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return r("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),u=n.call(a,"finallyLoc");if(l&&u){if(this.prev<a.catchLoc)return r(a.catchLoc,!0);if(this.prev<a.finallyLoc)return r(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return r(a.catchLoc,!0)}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return r(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var s=a?a.completion:{};return s.type=e,s.arg=t,a?(this.method="next",this.next=a.finallyLoc,f):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),S(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;S(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:T(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}function uk(e){return(uk="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function uS(e,t,n,r,i,a,s){try{var l=e[a](s),u=l.value}catch(e){n(e);return}l.done?t(u):Promise.resolve(u).then(r,i)}function uE(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var a=e.apply(t,n);function s(e){uS(a,r,i,s,l,"next",e)}function l(e){uS(a,r,i,s,l,"throw",e)}s(void 0)})}}function uT(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function uA(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,uj(r.key),r)}}function uO(e,t,n){return t&&uA(e.prototype,t),n&&uA(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function uC(e,t,n){return(t=uj(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function uI(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&uR(e,t)}function uD(e){return(uD=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function uR(e,t){return(uR=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function uU(){if("undefined"==typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function uL(e,t,n){return(uL=uU()?Reflect.construct.bind():function(e,t,n){var r=[null];r.push.apply(r,t);var i=new(Function.bind.apply(e,r));return n&&uR(i,n.prototype),i}).apply(null,arguments)}function uP(e){var t="function"==typeof Map?new Map:void 0;return(uP=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return uL(e,arguments,uD(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),uR(n,e)})(e)}function uB(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uM(e){var t=uU();return function(){var n,r=uD(e);n=t?Reflect.construct(r,arguments,uD(this).constructor):r.apply(this,arguments);if(n&&("object"==typeof n||"function"==typeof n))return n;if(void 0!==n)throw TypeError("Derived constructors may only return object or undefined");return uB(this)}}function uN(){return(uN="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=uD(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}}).apply(this,arguments)}function uF(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function uj(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}var uz=function(){function e(){uT(this,e)}return uO(e,null,[{key:"start",value:function(e){return!e||!e.length||1===e.length&&e.end(0)-e.start(0)<1e-6||1===e.length&&0>e.start(0)?0:e.start(0)}},{key:"end",value:function(e){return!e||!e.length||1===e.length&&e.end(0)-e.start(0)<1e-6?0:e.end(e.length-1)}},{key:"get",value:function(e){if(e)try{return e.buffered}catch(e){}}},{key:"buffers",value:function(e,t){if(!e||!e.length)return[];for(var n=[],r=0,i=e.length;r<i;r++){var a=n.length;if(a&&t){var s=n[a-1],l=s[1];if(e.start(r)-l<=t){var u=e.end(r);u>l&&(s[1]=u)}else n.push([e.start(r),e.end(r)])}else n.push([e.start(r),e.end(r)])}return n}},{key:"totalLength",value:function(e){return e&&e.length?e.reduce(function(e,t){return e+(t[1]-t[0])},0):0}},{key:"info",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(!t||!t.length)return{start:0,end:0,buffers:[]};for(var i=0,a=0,s=0,l=0,u=0,c=0,d=0,f=e.buffers(t,r),h=0,p=f.length;h<p;h++){var m=f[h];if(n+r>=m[0]&&n<=m[1])i=m[0],a=m[1],s=h;else if(n+r<m[0]){l=m[0],u=m[1];break}else n+r>m[1]&&(c=m[0],d=m[1])}return{start:i,end:a,index:s,buffers:f,nextStart:l,nextEnd:u,prevStart:c,prevEnd:d,currentTime:n,behind:n-i,remaining:a?a-n:0,length:e.totalLength&&e.totalLength(f)}}},{key:"isBuffered",value:function(t,n){if(t){var r=e.get(t);if(null!=r&&r.length){for(var i=0;i<r.length;i++)if(n>=r.start(i)&&n<=r.end(i))return!0}}return!1}}]),e}(),uG="undefined"!=typeof window,uV={MANIFEST:"manifest",NETWORK:"network",NETWORK_TIMEOUT:"network_timeout",NETWORK_FORBIDDEN:"network_forbidden",NETWORK_NOTFOUND:"network_notfound",NETWROK_RANGE_NOT_SATISFIABLE:"network_range_not_satisfiable",DEMUX:"demux",REMUX:"remux",MEDIA:"media",DRM:"drm",OTHER:"other",RUNTIME:"runtime",SUB_TYPES:{FLV:"FLV",HLS:"HLS",MP4:"MP4",FMP4:"FMP4",MSE_ADD_SB:"MSE_ADD_SB",MSE_APPEND_BUFFER:"MSE_APPEND_BUFFER",MSE_OTHER:"MSE_OTHER",MSE_FULL:"MSE_FULL",MSE_CHANGE_TYPE:"MSE_CHANGE_TYPE",OPTION:"OPTION",DASH:"DASH",LICENSE:"LICENSE",CUSTOM_LICENSE:"CUSTOM_LICENSE",MSE_HIJACK:"MSE_HIJACK",EME_HIJACK:"EME_HIJACK",SIDX:"SIDX",NO_CANPLAY_ERROR:"NO_CANPLAY_ERROR",BUFFERBREAK_ERROR:"BUFFERBREAK_ERROR",WAITING_TIMEOUT_ERROR:"WAITING_TIMEOUT_ERROR",MEDIA_ERR_ABORTED:"MEDIA_ERR_ABORTED",MEDIA_ERR_NETWORK:"MEDIA_ERR_NETWORK",MEDIA_ERR_DECODE:"MEDIA_ERR_DECODE",MEDIA_ERR_SRC_NOT_SUPPORTED:"MEDIA_ERR_SRC_NOT_SUPPORTED",MEDIA_ERR_CODEC_NOT_SUPPORTED:"MEDIA_ERR_CODEC_NOT_SUPPORTED",MEDIA_ERR_URL_EMPTY:"MEDIA_ERR_URL_EMPTY"}},uH=(uC(aF={},uV.MANIFEST,{HLS:1100,DASH:1200}),uC(aF,uV.NETWORK,2100),uC(aF,uV.NETWORK_TIMEOUT,2101),uC(aF,uV.NETWORK_FORBIDDEN,2103),uC(aF,uV.NETWORK_NOTFOUND,2104),uC(aF,uV.NETWROK_RANGE_NOT_SATISFIABLE,2116),uC(aF,uV.DEMUX,{FLV:3100,HLS:3200,MP4:3300,FMP4:3400,SIDX:3410}),uC(aF,uV.REMUX,{FMP4:4100,MP4:4200}),uC(aF,uV.MEDIA,{MEDIA_ERR_ABORTED:5101,MEDIA_ERR_NETWORK:5102,MEDIA_ERR_DECODE:5103,MEDIA_ERR_SRC_NOT_SUPPORTED:5104,MEDIA_ERR_CODEC_NOT_SUPPORTED:5105,MEDIA_ERR_URL_EMPTY:5106,MSE_ADD_SB:5200,MSE_APPEND_BUFFER:5201,MSE_OTHER:5202,MSE_FULL:5203,MSE_HIJACK:5204,MSE_CHANGE_TYPE:5205,EME_HIJACK:5301}),uC(aF,uV.DRM,{LICENSE:7100,CUSTOM_LICENSE:7200}),uC(aF,uV.OTHER,8e3),uC(aF,uV.RUNTIME,{NO_CANPLAY_ERROR:9001,BUFFERBREAK_ERROR:9002,WAITING_TIMEOUT_ERROR:9003}),aF),uW=function(e){uI(n,e);var t=uM(n);function n(e,r,i,a,s){var l;return uT(this,n),(l=t.call(this,s||(null==i?void 0:i.message))).errorType=e===uV.NETWORK_TIMEOUT?uV.NETWORK:e,l.originError=i,l.ext=a,l.errorCode=uH[e][r]||uH[e],l.errorMessage=l.message,l.errorCode||(l.errorType=uV.OTHER,l.errorCode=uH[l.errorType]),l}return uO(n,null,[{key:"create",value:function(e,t,r,i,a){return e instanceof n?e:(e instanceof Error&&(r=e,e=""),e||(e=uV.OTHER),new n(e,t,r,i,a))}},{key:"network",value:function(e){var t;return new n(null!=e&&e.isTimeout?uV.NETWORK_TIMEOUT:uV.NETWORK,null,e instanceof Error?e:null,{url:null==e?void 0:e.url,response:null==e?void 0:e.response,httpCode:null==e||null==(t=e.response)?void 0:t.status})}}]),n}(uP(Error)),uq={DEBUG:1,LOG:2,WARN:3,ERROR:4},uK=["Boolean","Number","String","Undefined","Null","Date","Object"],uJ=function(){function e(t,n){uT(this,e),this.name=t||"",this._prefix="[".concat(this.name,"]"),this.logCacheLevel=(null==n?void 0:n.logCacheLevel)||3,this.logMaxSize=(null==n?void 0:n.logMaxSize)||204800,this.logSize=0,this.logTextArray=[]}return uO(e,[{key:"debug",value:function(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];this.logCache.apply(this,[uq.DEBUG].concat(r)),e.disabled||(t=console).debug.apply(t,["[".concat(uZ(),"]"),this._prefix].concat(r))}},{key:"log",value:function(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];this.logCache.apply(this,[uq.LOG].concat(r)),e.disabled||(t=console).log.apply(t,["[".concat(uZ(),"]"),this._prefix].concat(r))}},{key:"warn",value:function(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];this.logCache.apply(this,[uq.WARN].concat(r)),e.disabled||(t=console).warn.apply(t,["[".concat(uZ(),"]"),this._prefix].concat(r))}},{key:"error",value:function(){for(var t,n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];this.logCache.apply(this,[uq.ERROR].concat(r)),e.disabled||(t=console).error.apply(t,["[".concat(uZ(),"]"),this._prefix].concat(r))}},{key:"logCache",value:function(e){if(!(e<this.logCacheLevel)){var t="";try{for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];var a=r.map(function(e){return function e(t,n,r){r||(r=1),n||(n=2);var i={};if(!t||"object"!==uk(t))return t;var a=Object.prototype.toString.call(t).slice(8,-1);if(!uK.includes(a))return a;if(!(r>n)){for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&(r===n?i[s]=function(e){if("object"!==uk(e))return e;var t=Object.prototype.toString.call(e).slice(8,-1);switch(t){case"Array":case"Uint8Array":case"ArrayBuffer":return t+"["+e.length+"]";case"Object":return"{}";default:return t}}(t[s]):"object"===uk(t[s])?i[s]=e(t[s],n,r+1):i[s]=t[s]);return i}}(e)});t="[".concat(uZ(),"]")+this._prefix+JSON.stringify(a)}catch(e){return}if(e>=this.logCacheLevel&&(this.logSize+=t.length,this.logTextArray.push(t)),this.logSize>this.logMaxSize){var s=this.logTextArray.shift();this.logSize-=s.length}}}},{key:"getLogCache",value:function(){var e=this.logTextArray.join("\n");return this.reset(),e}},{key:"reset",value:function(){this.logTextArray=[],this.logSize=0}},{key:"table",value:function(){var t;e.disabled||(console.group(this._prefix),(t=console).table.apply(t,arguments),console.groupEnd())}},{key:"setLogLevel",value:function(e){this.logCacheLevel=e}}],[{key:"enable",value:function(){e.disabled=!1}},{key:"disable",value:function(){e.disabled=!0}}]),e}();function uZ(){return new Date().toLocaleString()}function u$(){var e,t,n=new Promise(function(n,r){e=n,t=r});return n.used=!1,n.resolve=function(){return n.used=!0,e.apply(void 0,arguments)},n.reject=function(){return n.used=!0,t.apply(void 0,arguments)},n}function uY(){try{return parseInt(performance.now(),10)}catch(e){return new Date().getTime()}}uC(uJ,"disabled",!0);var uQ={stringify:function(e){try{return JSON.stringify(e)}catch(e){return""}}};function uX(){var e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];try{if(!uG)return null;if(e&&"undefined"!=typeof ManagedMediaSource)return ManagedMediaSource;return window.MediaSource}catch(e){}}function u0(e){return/ManagedMediaSource/gi.test(Object.prototype.toString.call(e))}var u1={APPEND:"appendBuffer",REMOVE:"removeBuffer",UPDATE_DURATION:"updateDuration"},u2=function(){var e,t,n;function r(e,t){var n=this;uT(this,r),uC(this,"media",null),uC(this,"mediaSource",null),uC(this,"_openPromise",u$()),uC(this,"_queue",Object.create(null)),uC(this,"_sourceBuffer",Object.create(null)),uC(this,"_mseFullFlag",{}),uC(this,"_st",0),uC(this,"_opst",0),uC(this,"_logger",null),uC(this,"_config",null),uC(this,"_url",null),uC(this,"_onStartStreaming",function(){n._logger.debug("startstreaming")}),uC(this,"_onEndStreaming",function(){n._logger.debug("endstreaming")}),uC(this,"_onSBUpdateEnd",function(e){var t=n._queue[e];if(t){var r=t[0];if((null==r?void 0:r.opName)!==u1.UPDATE_DURATION&&t.shift(),r){var i,a,s=uY()-n._opst;n._logger.debug("UpdateEnd(".concat(e,"/").concat(r.opName,")"),uQ.stringify(function(e){var t=[];if(e instanceof TimeRanges)for(var n=0;n<e.length;n++)t.push({start:e.start(n),end:e.end(n)});return t}(null==(i=n._sourceBuffer[e])?void 0:i.buffered)),s,r.context),r.promise.resolve({name:r.opName,context:r.context,costtime:s});var l=null==(a=r.context)?void 0:a.callback;l&&"function"==typeof l&&l(r.context),n._startQueue(e)}}}),uC(this,"_onSBUpdateError",function(e,t){var r=n._queue[e];if(r){var i=r[0];i&&(n._logger.error("UpdateError",e,i.opName,i.context),i.promise.reject(new uW(uV.MEDIA,uV.SUB_TYPES.MSE_APPEND_BUFFER,t)))}}),this._config=Object.assign(r.getDefaultConfig(),t),e&&this.bindMedia(e),this._logger=new uJ("MSE"),this._config.openLog&&uJ.enable()}return uO(r,[{key:"isOpened",get:function(){var e;return(null==(e=this.mediaSource)?void 0:e.readyState)==="open"}},{key:"hasOpTasks",get:function(){var e=this,t=!1;return Object.keys(this._queue).forEach(function(n){var r=e._queue[n];Array.isArray(r)&&(t||(t=r.length>0))}),t}},{key:"url",get:function(){return this._url}},{key:"duration",get:function(){var e;return(null==(e=this.mediaSource)?void 0:e.duration)||-1}},{key:"isEnded",get:function(){return!!this.mediaSource&&"ended"===this.mediaSource.readyState}},{key:"streaming",get:function(){return!u0(this.mediaSource)||this.mediaSource.streaming}},{key:"isFull",value:function(e){return e?this._mseFullFlag[e]:this._mseFullFlag[r.VIDEO]}},{key:"updateDuration",value:function(e){var t=this,n=this.mediaSource&&this.mediaSource.duration>e;if(this.mediaSource&&this.mediaSource.duration>e){var r=0;if(Object.keys(this._sourceBuffer).forEach(function(e){try{r=Math.max(t.bufferEnd(e)||0,r)}catch(e){}}),e<r)return Promise.resolve()}return this._enqueueBlockingOp(function(){if(t.isEnded)return void t._logger.debug("setDuration but ended");t.mediaSource&&(t.mediaSource.duration=e,t._logger.debug("setDuration",e))},u1.UPDATE_DURATION,{isReduceDuration:n})}},{key:"open",value:function(){var e=this;if(this._openPromise.used&&!this.isOpened&&this.mediaSource){var t=this.mediaSource;t.addEventListener("sourceopen",function n(){var r=uY()-e._st;e._logger.debug("sourceopen",r),t.removeEventListener("sourceopen",n),e._openPromise.resolve({costtime:r})}),this._openPromise=u$()}return this._openPromise}},{key:"bindMedia",value:(e=uE(ux().mark(function e(t){var n,r,i,a,s=this;return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(this.mediaSource||this.media)){e.next=3;break}return e.next=3,this.unbindMedia();case 3:if(n=uX(this._config.preferMMS),!(!t||!n)){e.next=6;break}throw Error("Param media or MediaSource does not exist");case 6:return this.media=t,i=u0(r=this.mediaSource=new n),this._st=uY(),a=function e(){var n=uY()-s._st;s._logger.debug("sourceopen"),r.removeEventListener("sourceopen",e),URL.revokeObjectURL(t.src),s._openPromise.resolve({costtime:n})},r.addEventListener("sourceopen",a),i&&(r.addEventListener("startstreaming",this._onStartStreaming),r.addEventListener("endstreaming",this._onEndStreaming)),this._url=URL.createObjectURL(r),t.src=this._url,t.disableRemotePlayback=i,e.abrupt("return",this._openPromise);case 17:case"end":return e.stop()}},e,this)})),function(t){return e.apply(this,arguments)})},{key:"unbindMedia",value:(t=uE(ux().mark(function e(){var t,n,r,i=this;return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this._openPromise.used||this._openPromise.resolve(),t=this.mediaSource){if(Object.keys(this._queue).forEach(function(e){var t=i._queue[e];t&&t.forEach(function(e){var t,n;return null==(t=e.promise)||null==(n=t.resolve)?void 0:n.call(t)})}),n=!!this.media&&this.media.readyState>=1,r="open"===t.readyState,n&&r)try{t.endOfStream()}catch(e){}Object.keys(this._sourceBuffer).forEach(function(e){try{t.removeSourceBuffer(i._sourceBuffer[e])}catch(e){}}),u0(t)&&(t.removeEventListener("startstreaming",this._onStartStreaming),t.removeEventListener("endstreaming",this._onEndStreaming))}if(this.media){this.media.disableRemotePlayback=!1,this.media.removeAttribute("src");try{this.media.load()}catch(e){}this.media=null}this.mediaSource=null,this._openPromise=u$(),this._queue=Object.create(null),this._sourceBuffer=Object.create(null);case 8:case"end":return e.stop()}},e,this)})),function(){return t.apply(this,arguments)})},{key:"createSource",value:function(e,t){var n;if(!this._sourceBuffer[e]&&this.mediaSource){try{n=this._sourceBuffer[e]=this.mediaSource.addSourceBuffer(t)}catch(e){throw new uW(uV.MEDIA,uV.SUB_TYPES.MSE_ADD_SB,e)}n.mimeType=t,n.addEventListener("updateend",this._onSBUpdateEnd.bind(this,e)),n.addEventListener("error",this._onSBUpdateError.bind(this,e))}}},{key:"changeType",value:function(e,t){var n=this,r=this._sourceBuffer[e];return this.mediaSource&&r&&r.mimeType!==t?"function"!=typeof r.changeType?Promise.reject(new uW(uV.MEDIA,uV.SUB_TYPES.MSE_CHANGE_TYPE,Error("changeType is not a function"))):this._enqueueOp(e,function(){try{r.changeType(t)}catch(e){throw new uW(uV.MEDIA,uV.SUB_TYPES.MSE_CHANGE_TYPE,e)}r.mimeType=t,n._onSBUpdateEnd(e)},"changeType",{mimeType:t}):Promise.resolve()}},{key:"createOrChangeSource",value:function(e,t){return this.createSource(e,t),this.changeType(e,t)}},{key:"append",value:function(e,t,n){var r=this;return t&&t.byteLength&&this._sourceBuffer[e]?this._enqueueOp(e,function(){var i;r.mediaSource&&!r.media.error&&(r._logger.debug("MSE APPEND START",n),r._opst=uY(),null==(i=r._sourceBuffer[e])||i.appendBuffer(t))},u1.APPEND,n):Promise.resolve()}},{key:"remove",value:function(e,t,n,r){var i=this,a=!1;return this._mseFullFlag[e]&&(a=!0),this._enqueueOp(e,function(){if(i.mediaSource&&!i.media.error){var a=i._sourceBuffer[e];if(t>=n||!a)return void i._onSBUpdateEnd(e);i._opst=uY(),i._logger.debug("MSE REMOVE START",e,t,n,r),a.remove(t,n)}},u1.REMOVE,r,a)}},{key:"clearBuffer",value:function(e,t){var n,r=this;return Object.keys(this._sourceBuffer).forEach(function(i){n=r.remove(i,e,t)}),n||Promise.resolve()}},{key:"clearAllBuffer",value:function(){var e,t=this;return Object.keys(this._sourceBuffer).forEach(function(n){var r=t._sourceBuffer[n];e=t.remove(n,0,uz.end(uz.get(r)))}),e}},{key:"clearOpQueues",value:function(e,t){this._logger.debug("MSE clearOpQueue START");var n,r=this._queue[e];if(t&&r){this._queue[e]=[];return}if(r&&r[e]&&!(r.length<5)){var i=[];r.forEach(function(e){e.context&&e.context.isinit&&i.push(e)}),this._queue[e]=r.slice(0,2),i.length>0&&(n=this._queue[e]).push.apply(n,i)}}},{key:"endOfStream",value:function(e){var t=this;return this.mediaSource&&"open"===this.mediaSource.readyState?this._enqueueBlockingOp(function(){var n=t.mediaSource;n&&"open"===n.readyState&&(t._logger.debug("MSE endOfStream START"),e?n.endOfStream(e):n.endOfStream())},"endOfStream"):Promise.resolve()}},{key:"setLiveSeekableRange",value:function(e,t){var n=this.mediaSource;e<0||t<e||null==n||!n.setLiveSeekableRange||"open"!==n.readyState||n.setLiveSeekableRange(e,t)}},{key:"getSourceBuffer",value:function(e){return this._sourceBuffer[e]}},{key:"buffered",value:function(e){return uz.get(this._sourceBuffer[e])}},{key:"bufferStart",value:function(e){return uz.start(this.buffered(e))}},{key:"bufferEnd",value:function(e){return uz.end(this.buffered(e))}},{key:"_enqueueOp",value:function(e,t,n,r,i){var a=this;if(!this.mediaSource)return Promise.resolve();var s=this._queue[e]=this._queue[e]||[],l={exec:t,promise:u$(),opName:n,context:r};return i?(s.splice(0,0,l),this._mseFullFlag[e]=!1,this._startQueue(e)):s.push(l),this.isOpened||this.isEnded?1===s.length&&this._startQueue(e):this._openPromise.then(function(){1===s.length&&a._startQueue(e)}),l.promise}},{key:"_enqueueBlockingOp",value:(n=uE(ux().mark(function e(t,n,r){var i,a,s=this;return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.mediaSource){e.next=2;break}return e.abrupt("return",Promise.resolve());case 2:if((i=Object.keys(this._sourceBuffer)).length){e.next=5;break}return e.abrupt("return",t());case 5:return a=[],i.forEach(function(e){var t=s._queue[e],i=u$();a.push(i),t.push({exec:function(){i.resolve()},promise:i,opName:n,context:r}),1===t.length&&s._startQueue(e)}),e.abrupt("return",Promise.all(a).then(function(){try{return t()}finally{i.forEach(function(e){var t=s._queue[e],n=s._sourceBuffer[e];null==t||t.shift(),n&&n.updating||s._startQueue(e)})}}));case 8:case"end":return e.stop()}},e,this)})),function(e,t,r){return n.apply(this,arguments)})},{key:"_startQueue",value:function(e){var t=this._queue[e];if(t){var n,r,i=t[0];if(i&&!this._mseFullFlag[e])try{i.exec()}catch(a){a&&a.message&&a.message.indexOf("SourceBuffer is full")>=0?(this._mseFullFlag[e]=!0,i.context&&"object"===uk(i.context)&&(i.context.isFull=!0),this._logger.error("[MSE error], context,",i.context," ,name,",i.opName,",err,SourceBuffer is full"),null==i||null==(n=i.promise)||n.reject(new uW(uV.MEDIA,uV.SUB_TYPES.MSE_FULL,a))):(this._logger.error(a),null==i||null==(r=i.promise)||r.reject(a.constructor===uW?a:new uW(uV.MEDIA,uV.SUB_TYPES.MSE_OTHER,a)),t.shift(),this._startQueue(e))}}}},{key:"setTimeoffset",value:function(e,t,n){var r=this;return this._enqueueOp(e,function(){t<0&&(t+=.001),r._sourceBuffer[e].timestampOffset=t,r._onSBUpdateEnd(e)},"setTimeoffset",n)}},{key:"abort",value:function(e,t){var n=this;return this.isOpened?this._enqueueOp(e,function(){n._sourceBuffer[e].abort(),n._onSBUpdateEnd(e)},"abort",t):Promise.resolve()}}],[{key:"isSupported",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:'video/mp4; codecs="avc1.42E01E,mp4a.40.2"',t=uX();if(!t)return!1;try{return t.isTypeSupported(e)}catch(t){return this._logger.error(e,t),!1}}},{key:"isMMSOnly",value:function(){return"undefined"!=typeof ManagedMediaSource&&"undefined"==typeof MediaSource}},{key:"getDefaultConfig",value:function(){return{openLog:!1,preferMMS:!1}}}]),r}();uC(u2,"VIDEO","video"),uC(u2,"AUDIO","audio");var u5={FETCH:"fetch",XHR:"xhr"},u3={ARRAY_BUFFER:"arraybuffer",TEXT:"text",JSON:"json"},u6=function(e){uI(n,e);var t=uM(n);function n(e,r,i,a){var s;return uT(this,n),uC(uB(s=t.call(this,a)),"retryCount",0),uC(uB(s),"isTimeout",!1),uC(uB(s),"loaderType",u5.FETCH),uC(uB(s),"startTime",0),uC(uB(s),"endTime",0),uC(uB(s),"options",{}),s.url=e,s.request=r,s.response=i,s}return uO(n)}(uP(Error)),u4=Object.prototype.toString;function u8(e){if("[object Object]"!==u4.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function u9(e){if(e&&null!==e[0]&&void 0!==e[0]&&(0!==e[0]||null!==e[1]&&void 0!==e[1])){var t="bytes="+e[0]+"-";return e[1]&&(t+=e[1]),t}}function u7(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function ce(e,t){if(e){if(!t)return e;var n,r=Object.keys(t).map(function(e){if(null!=(n=t[e]))return Array.isArray(n)?e+="[]":n=[n],n.map(function(t){var n,r;return(n=t,"[object Date]"===u4.call(n))?t=t.toISOString():null!==(r=t)&&"object"===uk(r)&&(t=JSON.stringify(t)),"".concat(u7(e),"=").concat(u7(t))}).join("&")}).filter(Boolean).join("&");if(r){var i=e.indexOf("#");-1!==i&&(e=e.slice(0,i)),e+=(-1===e.indexOf("?")?"?":"&")+r}return e}}function ct(e,t,n,r,i,a,s,l,u,c,d){return i=null!=i?parseFloat(i):null,Number.isNaN(r=parseInt(r||"0",10))&&(r=0),{data:e,done:t,options:{range:u,vid:c,index:l,contentLength:r,age:i,startTime:a,firstByteTime:s,endTime:Date.now(),priOptions:d},response:n}}function cn(e,t){return Math.round(8*e*1e3/t/1024)}var cr={ERROR:"error",TTFB:"core.ttfb",LOAD_START:"core.loadstart",LOAD_RESPONSE_HEADERS:"core.loadresponseheaders",LOAD_COMPLETE:"core.loadcomplete",LOAD_RETRY:"core.loadretry",SOURCEBUFFER_CREATED:"core.sourcebuffercreated",ANALYZE_DURATION_EXCEEDED:"core.analyzedurationexceeded",APPEND_BUFFER:"core.appendbuffer",REMOVE_BUFFER:"core.removebuffer",BUFFEREOS:"core.buffereos",KEYFRAME:"core.keyframe",CHASEFRAME:"core.chaseframe",METADATA_PARSED:"core.metadataparsed",SEI:"core.sei",SEI_IN_TIME:"core.seiintime",FLV_SCRIPT_DATA:"core.flvscriptdata",SWITCH_URL_SUCCESS:"core.switchurlsuccess",SWITCH_URL_FAILED:"core.switchurlfailed",DEMUXED_TRACK:"core.demuxedtrack",STREAM_EXCEPTION:"core.streamexception",LARGE_AV_FIRST_FRAME_GAP_DETECT:"LARGE_AV_FIRST_FRAME_GAP_DETECT",LARGE_VIDEO_DTS_GAP_DETECT:"LARGE_VIDEO_DTS_GAP_DETECT",LARGE_AUDIO_DTS_GAP_DETECT:"LARGE_AUDIO_DTS_GAP_DETECT",AUDIO_GAP_DETECT:"AUDIO_GAP_DETECT",AUDIO_OVERLAP_DETECT:"AUDIO_OVERLAP_DETECT",MAX_DTS_DELTA_WITH_NEXT_SEGMENT_DETECT:"MAX_DTS_DELTA_WITH_NEXT_SEGMENT_DETECT",REAL_TIME_SPEED:"real_time_speed"},ci=function(e){uI(r,e);var t,n=uM(r);function r(){var e;return uT(this,r),uC(uB(e=n.call(this)),"_abortController",null),uC(uB(e),"_timeoutTimer",null),uC(uB(e),"_reader",null),uC(uB(e),"_response",null),uC(uB(e),"_aborted",!1),uC(uB(e),"_index",-1),uC(uB(e),"_range",null),uC(uB(e),"_receivedLength",0),uC(uB(e),"_running",!1),uC(uB(e),"_logger",null),uC(uB(e),"_vid",""),uC(uB(e),"_onProcessMinLen",0),uC(uB(e),"_onCancel",null),uC(uB(e),"_priOptions",null),e}return uO(r,[{key:"load",value:function(e){var t,n=this,r=e.url,i=e.vid,a=e.timeout,s=e.responseType,l=e.onProgress,u=e.index,c=e.onTimeout,d=e.onCancel,f=e.range,h=e.transformResponse,p=e.request,m=e.params,g=e.logger,y=e.method,_=e.headers,b=e.body,w=e.mode,x=e.credentials,k=e.cache,S=e.redirect,E=e.referrer,T=e.referrerPolicy,A=e.onProcessMinLen,O=e.priOptions;this._logger=g,this._aborted=!1,this._onProcessMinLen=A,this._onCancel=d,this._abortController="undefined"!=typeof AbortController&&new AbortController,this._running=!0,this._index=u,this._range=f||[0,0],this._vid=i||r,this._priOptions=O||{};var C={method:y,headers:_,body:b,mode:w,credentials:x,cache:k,redirect:S,referrer:E,referrerPolicy:T,signal:null==(t=this._abortController)?void 0:t.signal},I=!1;clearTimeout(this._timeoutTimer),r=ce(r,m);var D=u9(f);D&&(_=p?p.headers:C.headers=C.headers||(Headers?new Headers:{}),Headers&&_ instanceof Headers?_.append("Range",D):_.Range=D),a&&(this._timeoutTimer=setTimeout(function(){if(I=!0,n.cancel(),c){var e=new u6(r,C,null,"timeout");e.isTimeout=!0,c(e,{index:n._index,range:n._range,vid:n._vid,priOptions:n._priOptions})}},a));var R=Date.now();return this._logger.debug("[fetch load start], index,",u,",range,",f),new Promise(function(e,t){var i;fetch(p||r,p?void 0:C).then((i=uE(ux().mark(function i(a){var c,d,p,m;return ux().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:if(clearTimeout(n._timeoutTimer),n._response=a,!(n._aborted||!n._running)){i.next=4;break}return i.abrupt("return");case 4:if(h&&(a=h(a,r)||a),a.ok){i.next=7;break}throw new u6(r,C,a,"bad network response");case 7:if(c=Date.now(),s!==u3.TEXT){i.next=15;break}return i.next=11,a.text();case 11:case 18:d=i.sent,n._running=!1,i.next=37;break;case 15:if(s!==u3.JSON){i.next=22;break}return i.next=18,a.json();case 22:if(!l){i.next=29;break}return n.resolve=e,n.reject=t,n._loadChunk(a,l,R,c),i.abrupt("return");case 29:return i.next=31,a.arrayBuffer();case 31:d=new Uint8Array(d=i.sent),n._running=!1,p=Date.now()-R,m=cn(d.byteLength,p),n.emit(cr.REAL_TIME_SPEED,{speed:m,len:d.byteLength,time:p,vid:n._vid,index:n._index,range:n._range,priOptions:n._priOptions});case 37:n._logger.debug("[fetch load end], index,",u,",range,",f),e(ct(d,!0,a,a.headers.get("Content-Length"),a.headers.get("age"),R,c,u,f,n._vid,n._priOptions));case 39:case"end":return i.stop()}},i)})),function(e){return i.apply(this,arguments)})).catch(function(e){var i;clearTimeout(n._timeoutTimer),n._running=!1,(!n._aborted||I)&&((e=e instanceof u6?e:new u6(r,C,null,null==(i=e)?void 0:i.message)).startTime=R,e.endTime=Date.now(),e.isTimeout=I,e.options={index:n._index,range:n._range,vid:n._vid,priOptions:n._priOptions},t(e))})})}},{key:"cancel",value:(t=uE(ux().mark(function e(){return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._aborted){e.next=2;break}return e.abrupt("return");case 2:if(this._aborted=!0,this._running=!1,!this._response){e.next=14;break}if(e.prev=5,!this._reader){e.next=9;break}return e.next=9,this._reader.cancel();case 9:e.next=13;break;case 11:e.prev=11,e.t0=e.catch(5);case 13:this._response=this._reader=null;case 14:if(this._abortController){try{this._abortController.abort()}catch(e){}this._abortController=null}this._onCancel&&this._onCancel({index:this._index,range:this._range,vid:this._vid,priOptions:this._priOptions});case 16:case"end":return e.stop()}},e,this,[[5,11]])})),function(){return t.apply(this,arguments)})},{key:"_loadChunk",value:function(e,t,n,r){var i,a,s,l,u=this;if(!e.body||!e.body.getReader){this._running=!1;var c=new u6(e.url,"",e,"onProgress of bad response.body.getReader");c.options={index:this._index,range:this._range,vid:this._vid,priOptions:this._priOptions},this.reject(c);return}this._onProcessMinLen>0&&(this._cache=new Uint8Array(2097152),this._writeIdx=0);var d=this._reader=e.body.getReader(),f=(i=uE(ux().mark(function i(){var c,h,p,m,g,y,_,b;return ux().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:return s=Date.now(),i.prev=1,i.next=4,d.read();case 4:a=i.sent,l=Date.now(),i.next=13;break;case 8:return i.prev=8,i.t0=i.catch(1),l=Date.now(),u._aborted||(u._running=!1,i.t0.options={index:u._index,range:u._range,vid:u._vid,priOptions:u._priOptions},u.reject(i.t0)),i.abrupt("return");case 13:if(p=(h=(null==(c=u._range)?void 0:c.length)>0?u._range[0]:0)+u._receivedLength,!u._aborted){i.next=19;break}return u._running=!1,t(void 0,!1,{range:[p,p],vid:u._vid,index:u._index,startTime:s,endTime:l,st:n,firstByteTime:r,priOptions:u._priOptions},e),i.abrupt("return");case 19:m=a.value?a.value.byteLength:0,u._receivedLength+=m,u._logger.debug("【fetchLoader,onProgress call】,task,",u._range,", start,",p,", end,",h+u._receivedLength,", done,",a.done),u._onProcessMinLen>0?u._writeIdx+m>=u._onProcessMinLen||a.done?((g=new Uint8Array(u._writeIdx+m)).set(u._cache.slice(0,u._writeIdx),0),m>0&&g.set(a.value,u._writeIdx),u._writeIdx=0,u._logger.debug("【fetchLoader,onProgress enough】,done,",a.done,",len,",g.byteLength,", writeIdx,",u._writeIdx)):m>0&&u._writeIdx+m<2097152?(u._cache.set(a.value,u._writeIdx),u._writeIdx+=m,u._logger.debug("【fetchLoader,onProgress cache】,len,",m,", writeIdx,",u._writeIdx)):m>0&&(y=new Uint8Array(u._writeIdx+m+2048),u._logger.debug("【fetchLoader,onProgress extra start】,size,",u._writeIdx+m+2048,", datalen,",m,", writeIdx,",u._writeIdx),y.set(u._cache.slice(0,u._writeIdx),0),m>0&&y.set(a.value,u._writeIdx),u._writeIdx+=m,delete u._cache,u._cache=y,u._logger.debug("【fetchLoader,onProgress extra end】,len,",m,", writeIdx,",u._writeIdx)):g=a.value,(g&&g.byteLength>0||a.done)&&t(g,a.done,{range:[u._range[0]+u._receivedLength-(g?g.byteLength:0),u._range[0]+u._receivedLength],vid:u._vid,index:u._index,startTime:s,endTime:l,st:n,firstByteTime:r,priOptions:u._priOptions},e),a.done?(_=Date.now()-n,b=cn(u._receivedLength,_),u.emit(cr.REAL_TIME_SPEED,{speed:b,len:u._receivedLength,time:_,vid:u._vid,index:u._index,range:u._range,priOptions:u._priOptions}),u._running=!1,u._logger.debug("[fetchLoader onProgress end],task,",u._range,",done,",a.done),u.resolve(ct(a,!0,e,e.headers.get("Content-Length"),e.headers.get("age"),n,r,u._index,u._range,u._vid,u._priOptions))):f();case 25:case"end":return i.stop()}},i,null,[[1,8]])})),function(){return i.apply(this,arguments)});f()}},{key:"receiveLen",get:function(){return this._receivedLength}},{key:"running",get:function(){return this._running},set:function(e){this._running=e}}],[{key:"isSupported",value:function(){return"undefined"!=typeof fetch}}]),r}(ua(us()).default),ca=function(e){uI(n,e);var t=uM(n);function n(){var e;return uT(this,n),uC(uB(e=t.call(this)),"_xhr",null),uC(uB(e),"_aborted",!1),uC(uB(e),"_timeoutTimer",null),uC(uB(e),"_range",null),uC(uB(e),"_receivedLength",0),uC(uB(e),"_url",null),uC(uB(e),"_onProgress",null),uC(uB(e),"_index",-1),uC(uB(e),"_headers",null),uC(uB(e),"_currentChunkSizeKB",384),uC(uB(e),"_timeout",null),uC(uB(e),"_xhr",null),uC(uB(e),"_withCredentials",null),uC(uB(e),"_startTime",-1),uC(uB(e),"_loadCompleteResolve",null),uC(uB(e),"_loadCompleteReject",null),uC(uB(e),"_runing",!1),uC(uB(e),"_logger",!1),uC(uB(e),"_vid",""),uC(uB(e),"_responseType",void 0),uC(uB(e),"_credentials",void 0),uC(uB(e),"_method",void 0),uC(uB(e),"_transformResponse",void 0),uC(uB(e),"_firstRtt",void 0),uC(uB(e),"_onCancel",null),uC(uB(e),"_priOptions",null),e}return uO(n,[{key:"load",value:function(e){var t=this;clearTimeout(this._timeoutTimer),this._logger=e.logger,this._range=e.range,this._onProgress=e.onProgress,this._index=e.index,this._headers=e.headers,this._withCredentials="include"===e.credentials||"same-origin"===e.credentials,this._body=e.body||null,e.method&&(this._method=e.method),this._timeout=e.timeout||null,this._runing=!0,this._vid=e.vid||e.url,this._responseType=e.responseType,this._firstRtt=-1,this._onTimeout=e.onTimeout,this._onCancel=e.onCancel,this._request=e.request,this._priOptions=e.priOptions||{},this._logger.debug("【xhrLoader task】, range",this._range),this._url=ce(e.url,e.params);var n=Date.now();return new Promise(function(e,n){t._loadCompleteResolve=e,t._loadCompleteReject=n,t._startLoad()}).catch(function(e){if(clearTimeout(t._timeoutTimer),t._runing=!1,!t._aborted)throw(e=e instanceof u6?e:new u6(t._url,t._request)).startTime=n,e.endTime=Date.now(),e.options={index:t._index,vid:t._vid,priOptions:t._priOptions},e})}},{key:"_startLoad",value:function(){var e=null;if(this._responseType===u3.ARRAY_BUFFER&&this._range&&this._range.length>1)if(this._onProgress){this._firstRtt=-1;var t=1024*this._currentChunkSizeKB,n=this._range[0]+this._receivedLength,r=this._range[1];t<this._range[1]-n&&(r=n+t),e=[n,r],this._logger.debug("[xhr_loader->],tast :",this._range,", SubRange, ",e)}else e=this._range,this._logger.debug("[xhr_loader->],tast :",this._range,", allRange, ",e);this._internalOpen(e)}},{key:"_internalOpen",value:function(e){var t=this;try{this._startTime=Date.now();var n=this._xhr=new XMLHttpRequest;n.open(this._method||"GET",this._url,!0),n.responseType=this._responseType,this._timeout&&(n.timeout=this._timeout),n.withCredentials=this._withCredentials,n.onload=this._onLoad.bind(this),n.onreadystatechange=this._onReadyStatechange.bind(this),n.onerror=function(e){t._running=!1;var n,r,i,a=new u6(t._url,t._request,null==e||null==(n=e.currentTarget)?void 0:n.response,"xhr.onerror.status:"+(null==e||null==(r=e.currentTarget)?void 0:r.status)+",statusText,"+(null==e||null==(i=e.currentTarget)?void 0:i.statusText));a.options={index:t._index,range:t._range,vid:t._vid,priOptions:t._priOptions},t._loadCompleteReject(a)},n.ontimeout=function(e){t.cancel();var n=new u6(t._url,t._request,{status:408},"timeout");t._onTimeout&&(n.isTimeout=!0,t._onTimeout(n,{index:t._index,range:t._range,vid:t._vid,priOptions:t._priOptions})),n.options={index:t._index,range:t._range,vid:t._vid,priOptions:t._priOptions},t._loadCompleteReject(n)};var r=this._headers||{},i=u9(e);i&&(r.Range=i),r&&Object.keys(r).forEach(function(e){n.setRequestHeader(e,r[e])}),this._logger.debug("[xhr.send->] tast,",this._range,",load sub range, ",e),n.send(this._body)}catch(t){t.options={index:this._index,range:e,vid:this._vid,priOptions:this._priOptions},this._loadCompleteReject(t)}}},{key:"_onReadyStatechange",value:function(e){2===e.target.readyState&&this._firstRtt<0&&(this._firstRtt=Date.now())}},{key:"_onLoad",value:function(e){var t=e.target.status;if(t<200||t>299){var n=new u6(this._url,null,uw(uw({},e.target.response),{},{status:t}),"bad response,status:"+t);return n.options={index:this._index,range:this._range,vid:this._vid,priOptions:this._priOptions},this._loadCompleteReject(n)}var r=null,i=!1,a=(null==(s=this._range)?void 0:s.length)>0?this._range[0]:0;if(this._responseType===u3.ARRAY_BUFFER){var s,l,u,c=new Uint8Array(e.target.response);if(l=a+this._receivedLength,c&&c.byteLength>0){this._receivedLength+=c.byteLength;var d=Date.now()-this._startTime,f=cn(this._receivedLength,d);this.emit(cr.REAL_TIME_SPEED,{speed:f,len:this._receivedLength,time:d,vid:this._vid,index:this._index,range:[l,a+this._receivedLength],priOptions:this._priOptions})}r=c,i=!((null==(u=this._range)?void 0:u.length)>1)||!this._range[1]||!(this._receivedLength<this._range[1]-this._range[0]),this._logger.debug("[xhr load done->], tast :",this._range,", start",l,"end ",a+this._receivedLength,",dataLen,",c?c.byteLength:0,",receivedLength",this._receivedLength,",index,",this._index,", done,",i)}else i=!0,r=e.target.response;var h={ok:t>=200&&t<300,status:t,statusText:this._xhr.statusText,url:this._xhr.responseURL,headers:this._getHeaders(this._xhr),body:this._xhr.response};this._transformResponse&&(h=this._transformResponse(h,this._url)||h),this._onProgress&&this._onProgress(r,i,{index:this._index,vid:this._vid,range:[l,a+this._receivedLength],startTime:this._startTime,endTime:Date.now(),priOptions:this._priOptions},h),i?(this._runing=!1,this._loadCompleteResolve&&this._loadCompleteResolve(ct(this._onProgress?null:r,i,h,h.headers["content-length"],h.headers.age,this._startTime,this._firstRtt,this._index,this._range,this._vid,this._priOptions))):this._startLoad()}},{key:"cancel",value:function(){if(!this._aborted&&(this._aborted=!0,this._runing=!1,uN(uD(n.prototype),"removeAllListeners",this).call(this),this._onCancel&&this._onCancel({index:this._index,range:this._range,vid:this._vid,priOptions:this._priOptions}),this._xhr))return this._xhr.abort()}},{key:"receiveLen",get:function(){return this._receivedLength}},{key:"running",get:function(){return this._running},set:function(e){this._running=e}},{key:"_getHeaders",value:function(e){var t,n=e.getAllResponseHeaders().trim().split("\r\n"),r={},i=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return uF(e,void 0);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return uF(e,void 0)}}(e))){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){l=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(l)throw a}}}}(n);try{for(i.s();!(t=i.n()).done;){var a=t.value.split(": ");r[a[0].toLowerCase()]=a.slice(1).join(": ")}}catch(e){i.e(e)}finally{i.f()}return r}}],[{key:"isSupported",value:function(){return"undefined"!=typeof XMLHttpRequest}}]),n}(ua(us()).default),cs=["retry","retryDelay","onRetryError","transformError"],co=function(){var e;function t(e,n){uT(this,t),this.promise=u$(),this.alive=!!n.onProgress,n.logger||(n.logger=new uJ("Loader")),this._loaderType=e,this._loader=e===u5.FETCH&&"undefined"!=typeof fetch?new ci:new ca,this._config=n,this._retryCount=0,this._retryTimer=null,this._canceled=!1,this._retryCheckFunc=n.retryCheckFunc,this._logger=n.logger}return uO(t,[{key:"exec",value:function(){var e,t=this,n=this._config,r=n.retry,i=n.retryDelay,a=n.onRetryError,s=n.transformError,l=function(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}(n,cs),u=(e=uE(ux().mark(function e(){var n,c,d;return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t._loader.load(l);case 3:n=e.sent,t.promise.resolve(n),e.next=27;break;case 7:if(e.prev=7,e.t0=e.catch(0),t._loader.running=!1,t._logger.debug("[task request catch err]",e.t0),!t._canceled){e.next=13;break}return e.abrupt("return");case 13:if(e.t0.loaderType=t._loaderType,e.t0.retryCount=t._retryCount,c=e.t0,s&&(c=s(c)||c),a&&t._retryCount>0&&a(c,t._retryCount,{index:l.index,vid:l.vid,range:l.range,priOptions:l.priOptions}),t._retryCount++,d=!0,t._retryCheckFunc&&(d=t._retryCheckFunc(e.t0)),!(d&&t._retryCount<=r)){e.next=26;break}return clearTimeout(t._retryTimer),t._logger.debug("[task request setTimeout],retry",t._retryCount,",retry range,",l.range),t._retryTimer=setTimeout(u,i),e.abrupt("return");case 26:t.promise.reject(c);case 27:case"end":return e.stop()}},e,null,[[0,7]])})),function(){return e.apply(this,arguments)});return u(),this.promise}},{key:"cancel",value:(e=uE(ux().mark(function e(){return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return clearTimeout(this._retryTimer),this._canceled=!0,this._loader.running=!1,e.abrupt("return",this._loader.cancel());case 4:case"end":return e.stop()}},e,this)})),function(){return e.apply(this,arguments)})},{key:"running",get:function(){return this._loader&&this._loader.running}},{key:"loader",get:function(){return this._loader}}]),t}(),cl=function(e){uI(r,e);var t,n=uM(r);function r(e){var t;return uT(this,r),uC(uB(t=n.call(this,e)),"type",u5.FETCH),uC(uB(t),"_queue",[]),uC(uB(t),"_alive",[]),uC(uB(t),"_currentTask",null),uC(uB(t),"_finnalUrl",""),uC(uB(t),"_config",void 0),t._config=uw({loaderType:u5.FETCH,retry:0,retryDelay:0,timeout:0,request:null,onTimeout:void 0,onProgress:void 0,onRetryError:void 0,transformRequest:void 0,transformResponse:void 0,transformError:void 0,responseType:u3.TEXT,range:void 0,url:"",params:void 0,method:"GET",headers:{},body:void 0,mode:void 0,credentials:void 0,cache:void 0,redirect:void 0,referrer:void 0,referrerPolicy:void 0,integrity:void 0,onProcessMinLen:0},e),t._config.loaderType!==u5.XHR&&ci.isSupported()||(t.type=u5.XHR),t.log=e.logger,t}return uO(r,[{key:"isFetch",value:function(){return this.type===u5.FETCH}},{key:"load",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};"string"!=typeof e&&e?n=e:n.url=e||n.url||this._config.url,(n=Object.assign({},this._config,n)).params&&(n.params=Object.assign({},n.params)),n.headers&&u8(n.headers)&&(n.headers=Object.assign({},n.headers)),n.body&&u8(n.body)&&(n.body=Object.assign({},n.body)),n.transformRequest&&(n=n.transformRequest(n)||n),n.logger=this.log;var r=new co(this.type,n);return r.loader.on(cr.REAL_TIME_SPEED,function(e){t.emit(cr.REAL_TIME_SPEED,e)}),this._queue.push(r),1!==this._queue.length||this._currentTask&&this._currentTask.running||this._processTask(),r.promise}},{key:"cancel",value:(t=uE(ux().mark(function e(){var t;return ux().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t=this._queue.map(function(e){return e.cancel()}).concat(this._alive.map(function(e){return e.cancel()})),this._currentTask&&t.push(this._currentTask.cancel()),this._queue=[],this._alive=[],e.next=6,Promise.all(t);case 6:return e.next=8,function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return new Promise(function(t){return setTimeout(t,e)})}();case 8:case"end":return e.stop()}},e,this)})),function(){return t.apply(this,arguments)})},{key:"_processTask",value:function(){var e=this;if(this._currentTask=this._queue.shift(),this._currentTask){this._currentTask.alive&&this._alive.push(this._currentTask);var t=this._currentTask.exec().catch(function(e){});t&&"function"==typeof t.finally&&t.finally(function(){var t,n;null!=(t=e._currentTask)&&t.alive&&(null==(n=e._alive)?void 0:n.length)>0&&(e._alive=e._alive.filter(function(t){return t&&t!==e._currentTask})),e._processTask()})}}}],[{key:"isFetchSupport",value:function(){return ci.isSupported()}}]),r}(ua(us()).default),cu=function(){function e(){uT(this,e),uC(this,"_prevCurrentTime",0)}return uO(e,[{key:"do",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1;if(e){var i=e.currentTime,a=0;if(this._prevCurrentTime===i){var s=uz.info(uz.get(e),i);if(!s.buffers.length)return;n&&s.nextStart||s.nextStart&&s.nextStart-i<t?a=s.nextStart+.1:s.end&&s.end-i>r&&!e.seeking&&(a=i+.1)}this._prevCurrentTime=i,a&&i!==a&&(e.currentTime=a)}}}]),e}(),cc=function(){function e(t){var n=this;uT(this,e),uC(this,"_seiSet",new Set),this.emitter=t,t.on(cr.SEI,function(e){e&&n._seiSet.add(e)})}return uO(e,[{key:"throw",value:function(e,t){var n=this;if(null!=e&&this._seiSet.size){var r=e-.2,i=e+.2,a=[];this._seiSet.forEach(function(e){e.time>=r&&e.time<=i&&a.push(e)}),a.forEach(function(e){n._seiSet.delete(e),n.emitter.emit(cr.SEI_IN_TIME,e)}),t&&this._seiSet.forEach(function(t){t.time<e-5&&n._seiSet.delete(t)})}}},{key:"reset",value:function(){this._seiSet.clear()}}]),e}(),cd=function(){function e(t){uT(this,e),uC(this,"_chunkSpeed",0),uC(this,"_chunkCache",[]),uC(this,"_speeds",[]),uC(this,"_totalSize",0),uC(this,"_totalCost",0),this._opts=t||{}}return uO(e,[{key:"addRecord",value:function(e,t){e&&t&&(this._speeds.push(8e3*e/t),this._speeds=this._speeds.slice(-3))}},{key:"addChunkRecord",value:function(e,t){if(e&&t&&!(e<((null==(n=this._opts)?void 0:n.skipChunkSize)||1e3))){this._totalSize+=e,this._totalCost+=t,this._chunkSpeed=8e3*e/t,this._chunkCache.push({size:e,duration:t,timestamp:performance.now()});var n,r,i=(null==(r=this._opts)?void 0:r.chunkCountForSpeed)||50;this._chunkCache.length>i&&(this._chunkCache=this._chunkCache.slice(-i))}}},{key:"getAvgSpeed",value:function(){if(!this._chunkCache.length&&!this._speeds.length)return 0;if(this._speeds.length)return this._speeds.reduce(function(e,t){return e+t})/this._speeds.length;var e,t=this._chunkCache[this._chunkCache.length-1],n=performance.now()-t.timestamp;return n>((null==(e=this._opts)?void 0:e.longtimeNoReceived)||3e3)&&this._chunkCache.push({size:0,duration:n,timestamp:performance.now()}),8e3*this._chunkCache.reduce(function(e,t){return e+t.size},0)/this._chunkCache.reduce(function(e,t){return e+t.duration},0)}},{key:"getLatestSpeed",value:function(){return this._chunkCache.length||this._speeds.length?this._speeds.length?this._speeds[this._speeds.length-1]:this._chunkSpeed:0}},{key:"getTotalSize",value:function(){return this._totalSize}},{key:"getTotalCost",value:function(){return this._totalCost}},{key:"reset",value:function(){this._chunkCache=[],this._speeds=[],this._totalSize=0,this._totalCost=0}}]),e}();ua(us());var cf=function(){function e(t){uT(this,e),uC(this,"encodeType",""),uC(this,"audioCodec",""),uC(this,"videoCodec",""),uC(this,"domain",""),uC(this,"fps",0),uC(this,"bitrate",0),uC(this,"width",0),uC(this,"height",0),uC(this,"samplerate",0),uC(this,"channelCount",0),uC(this,"gop",0),uC(this,"_bitsAccumulateSize",0),uC(this,"_bitsAccumulateDuration",0),uC(this,"_startGopId",-1),this._timescale=t}return uO(e,[{key:"getStats",value:function(){return{encodeType:this.encodeType,audioCodec:this.audioCodec,videoCodec:this.videoCodec,domain:this.domain,fps:this.fps,bitrate:this.bitrate,width:this.width,height:this.height,samplerate:this.samplerate,channelCount:this.channelCount,gop:this.gop}}},{key:"setEncodeType",value:function(e){this.encodeType=e}},{key:"setFpsFromScriptData",value:function(e){var t,n=e.data,r=null==n||null==(t=n.onMetaData)?void 0:t.framerate;r&&r>0&&r<100&&(this.fps=r)}},{key:"setVideoMeta",value:function(e){if(this.width=e.width,this.height=e.height,this.videoCodec=e.codec,this.encodeType=e.codecType,e.fpsNum&&e.fpsDen){var t=e.fpsNum/e.fpsDen;t>0&&t<100&&(this.fps=t)}}},{key:"setAudioMeta",value:function(e){this.audioCodec=e.codec,this.samplerate=e.sampleRate,this.channelCount=e.channelCount}},{key:"setDomain",value:function(e){this.domain=e.split("/").slice(2,3)[0]}},{key:"updateBitrate",value:function(e){var t=this;if((!this.fps||this.fps>=100)&&e.length){var n=e.reduce(function(e,t){return e+t.duration},0)/e.length;this.fps=Math.round(this._timescale/n)}e.forEach(function(e){-1===t._startGopId&&(t._startGopId=e.gopId),e.gopId===t._startGopId&&t.gop++,t._bitsAccumulateDuration+=e.duration/(t._timescale/1e3),t._bitsAccumulateSize+=e.units.reduce(function(e,t){return e+t.length},0),t._bitsAccumulateDuration>=1e3&&(t.bitrate=8*t._bitsAccumulateSize,t._bitsAccumulateDuration=0,t._bitsAccumulateSize=0)})}}]),e}(),ch=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3;uT(this,e),uC(this,"_core",null),uC(this,"_samples",[]),this._core=t,this._timescale=n,this._stats=new cf(n),this._bindEvents()}return uO(e,[{key:"getStats",value:function(){var e,t,n,r,i,a,s,l,u,c,d,f=(null==(e=this._core)?void 0:e.media)||{},h=f.currentTime,p=f.decodeFps;return uw(uw({},this._stats.getStats()),{},{downloadSpeed:(null==(t=this._core)||null==(n=t.speedInfo)?void 0:n.call(t).speed)||0,avgSpeed:(null==(r=this._core)||null==(i=r.speedInfo)?void 0:i.call(r).avgSpeed)||0,totalReceivedByte:(null==(a=this._core)||null==(s=a.speedInfo)?void 0:s.call(a).totalSize)||0,totalReceivedCost:(null==(l=this._core)||null==(u=l.speedInfo)?void 0:u.call(l).totalCost)||0,currentTime:void 0===h?0:h,bufferEnd:(null==(c=this._core)||null==(d=c.bufferInfo())?void 0:d.remaining)||0,decodeFps:void 0===p?0:p})}},{key:"_bindEvents",value:function(){var e=this;this._core.on(cr.DEMUXED_TRACK,function(t){var n=t.videoTrack;return e._stats.updateBitrate(n.samples)}),this._core.on(cr.FLV_SCRIPT_DATA,function(t){e._stats.setFpsFromScriptData(t)}),this._core.on(cr.METADATA_PARSED,function(t){"video"===t.type?e._stats.setVideoMeta(t.track):e._stats.setAudioMeta(t.track)}),this._core.on(cr.TTFB,function(t){e._stats.setDomain(t.responseUrl)})}},{key:"reset",value:function(){this._samples=[],this._stats=new cf(this._timescale)}}]),e}(),cp=ua(us());function cv(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,cT(r.key),r)}}function cg(e,t,n){return t&&cm(e.prototype,t),n&&cm(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function cy(e,t,n){return(t=cT(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function c_(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&cw(e,t)}function cb(e){return(cb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function cw(e,t){return(cw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function cx(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=cb(e);n=t?Reflect.construct(r,arguments,cb(this).constructor):r.apply(this,arguments);if(n&&("object"==typeof n||"function"==typeof n))return n;if(void 0!==n)throw TypeError("Derived constructors may only return object or undefined");if(void 0===this)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return this}}function ck(e){return function(e){if(Array.isArray(e))return cE(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||cS(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function cS(e,t){if(e){if("string"==typeof e)return cE(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return cE(e,t)}}function cE(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function cT(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}var cA={VIDEO:"video",AUDIO:"audio",METADATA:"metadata"},cO={AVC:"avc",HEVC:"hevc"},cC={AAC:"aac",G711PCMA:"g7110a",G711PCMU:"g7110m",OPUS:"opus",MP3:"mp3"},cI={LARGE_AV_SHIFT:"LARGE_AV_SHIFT",LARGE_VIDEO_GAP:"LARGE_VIDEO_GAP",LARGE_VIDEO_GAP_BETWEEN_CHUNK:"LARGE_VIDEO_GAP_BETWEEN_CHUNK",LARGE_AUDIO_GAP:"LARGE_AUDIO_GAP",AUDIO_FILLED:"AUDIO_FILLED",AUDIO_DROPPED:"AUDIO_DROPPED"},cD=function(){function e(){cv(this,e),cy(this,"id",1),cy(this,"type",cA.VIDEO),cy(this,"codecType",cO.AVC),cy(this,"pid",-1),cy(this,"hvcC",void 0),cy(this,"codec",""),cy(this,"timescale",0),cy(this,"formatTimescale",0),cy(this,"sequenceNumber",0),cy(this,"baseMediaDecodeTime",0),cy(this,"baseDts",0),cy(this,"duration",0),cy(this,"warnings",[]),cy(this,"samples",[]),cy(this,"pps",[]),cy(this,"sps",[]),cy(this,"vps",[]),cy(this,"fpsNum",0),cy(this,"fpsDen",0),cy(this,"sarRatio",[]),cy(this,"width",0),cy(this,"height",0),cy(this,"nalUnitSize",4),cy(this,"present",!1),cy(this,"isVideoEncryption",!1),cy(this,"isAudioEncryption",!1),cy(this,"isVideo",!0),cy(this,"lastKeyFrameDts",0),cy(this,"kid",null),cy(this,"pssh",null),cy(this,"ext",void 0)}return cg(e,[{key:"reset",value:function(){this.sequenceNumber=this.width=this.height=this.fpsDen=this.fpsNum=this.duration=this.baseMediaDecodeTime=this.timescale=0,this.codec="",this.present=!1,this.pid=-1,this.pps=[],this.sps=[],this.vps=[],this.sarRatio=[],this.samples=[],this.warnings=[],this.hvcC=null}},{key:"firstDts",get:function(){return this.samples.length?this.samples[0].dts:null}},{key:"firstPts",get:function(){return this.samples.length?this.samples[0].pts:null}},{key:"samplesDuration",get:function(){if(this.samples.length>0){var e=this.samples[0],t=this.samples[this.samples.length-1];return t.dts-e.dts+t.duration}return 0}},{key:"exist",value:function(){return!!/av01/.test(this.codec)||!!(this.pps.length&&this.sps.length&&this.codec)}},{key:"hasSample",value:function(){return!!this.samples.length}},{key:"isEncryption",get:function(){return this.isVideoEncryption}}]),e}(),cR=function(){function e(){cv(this,e),cy(this,"id",2),cy(this,"type",cA.AUDIO),cy(this,"codecType",cC.AAC),cy(this,"pid",-1),cy(this,"codec",""),cy(this,"container",""),cy(this,"sequenceNumber",0),cy(this,"sampleDuration",0),cy(this,"timescale",0),cy(this,"formatTimescale",0),cy(this,"baseMediaDecodeTime",0),cy(this,"duration",0),cy(this,"warnings",[]),cy(this,"samples",[]),cy(this,"baseDts",0),cy(this,"sampleSize",16),cy(this,"sampleRate",0),cy(this,"channelCount",0),cy(this,"objectType",0),cy(this,"sampleRateIndex",0),cy(this,"config",[]),cy(this,"present",!1),cy(this,"isVideoEncryption",!1),cy(this,"isAudioEncryption",!1),cy(this,"kid",null),cy(this,"ext",void 0)}return cg(e,[{key:"reset",value:function(){this.sequenceNumber=0,this.timescale=0,this.sampleDuration=0,this.sampleRate=0,this.channelCount=0,this.baseMediaDecodeTime=0,this.present=!1,this.pid=-1,this.codec="",this.samples=[],this.config=[],this.warnings=[]}},{key:"exist",value:function(){return!!(this.sampleRate&&this.channelCount&&(this.codec||this.container)&&(this.codecType===cC.AAC||this.codecType===cC.G711PCMA||this.codecType===cC.G711PCMU||this.codecType===cC.OPUS||this.codecType===cC.MP3))}},{key:"hasSample",value:function(){return!!this.samples.length}},{key:"isEncryption",get:function(){return this.isAudioEncryption}},{key:"firstDts",get:function(){return this.samples.length?this.samples[0].dts:null}},{key:"firstPts",get:function(){return this.samples.length?this.samples[0].pts:null}},{key:"samplesDuration",get:function(){if(this.samples.length>0){var e=this.samples[0],t=this.samples[this.samples.length-1];return t.dts-e.dts+t.duration}return 0}}]),e}(),cU=function(){function e(t,n,r){cv(this,e),cy(this,"flag",{}),cy(this,"keyframe",!1),cy(this,"gopId",0),cy(this,"duration",0),cy(this,"size",0),cy(this,"units",[]),cy(this,"chromaFormat",420),this.originPts=this.pts=t,this.originDts=this.dts=n,r&&(this.units=r)}return cg(e,[{key:"cts",get:function(){return this.pts-this.dts}},{key:"setToKeyframe",value:function(){this.keyframe=!0,this.flag.dependsOn=2,this.flag.isNonSyncSample=0}}]),e}(),cL=cg(function e(t,n,r,i){cv(this,e),cy(this,"duration",1024),cy(this,"flag",{dependsOn:2,isNonSyncSample:0}),cy(this,"keyframe",!0),this.originPts=this.pts=this.dts=t,this.data=n,this.size=n.byteLength,this.sampleOffset=i,r&&(this.duration=r)}),cP=cg(function e(t,n){cv(this,e),cy(this,"time",0),this.data=t,this.originPts=this.pts=n}),cB=function(e){c_(n,e);var t=cx(n);function n(){return cv(this,n),t.apply(this,arguments)}return cg(n)}(cP),cM=function(e){c_(n,e);var t=cx(n);function n(){return cv(this,n),t.apply(this,arguments)}return cg(n)}(cP),cN=function(){function e(){cv(this,e),cy(this,"id",3),cy(this,"type",cA.METADATA),cy(this,"timescale",0),cy(this,"flvScriptSamples",[]),cy(this,"seiSamples",[])}return cg(e,[{key:"exist",value:function(){return!!((this.flvScriptSamples.length||this.seiSamples.length)&&this.timescale)}},{key:"reset",value:function(){this.timescale=0,this.flvScriptSamples=[],this.seiSamples=[]}},{key:"hasSample",value:function(){return!!(this.flvScriptSamples.length||this.seiSamples.length)}}]),e}(),cF=function(){function e(t){cv(this,e),this.name=t||"",this._prefix="[".concat(this.name,"]")}return cg(e,[{key:"warn",value:function(){var t;if(!e.disabled){for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];(t=console).warn.apply(t,[this._prefix].concat(r))}}}],[{key:"enable",value:function(){e.disabled=!1}},{key:"disable",value:function(){e.disabled=!0}}]),e}();cy(cF,"disabled",!0);var cj="undefined"!=typeof window,cz=cj&&navigator.userAgent.toLocaleLowerCase(),cG=cj&&/^((?!chrome|android).)*safari/.test(cz),cV=cj&&cz.includes("firefox"),cH=cj&&cz.includes("android"),cW=function(){function e(){cv(this,e)}return cg(e,null,[{key:"getRateIndexByRate",value:function(t){return e.FREQ.indexOf(t)}},{key:"parseADTS",value:function(t,n){for(var r,i,a=t.length,s=0;s+2<a&&(255!==t[s]||(246&t[s+1])!=240);)s++;if(!(s>=a)){var l=s,u=[],c=(60&t[s+2])>>>2,d=e.FREQ[c];if(!d)throw Error("Invalid sampling index: ".concat(c));for(var f=((192&t[s+2])>>>6)+1,h=(1&t[s+2])<<2|(192&t[s+3])>>>6,p=e._getConfig(c,h,f),m=p.config,g=p.codec,y=0,_=e.getFrameDuration(d);s+7<a;){if(255!==t[s]||(246&t[s+1])!=240){s++;continue}if(!(i=(3&t[s+3])<<11|t[s+4]<<3|(224&t[s+5])>>5)||a-s<i)break;r=(1&~t[s+1])*2,u.push({pts:n+y*_,data:t.subarray(s+7+r,s+i)}),y++,s+=i}return{skip:l,remaining:s>=a?void 0:t.subarray(s),frames:u,samplingFrequencyIndex:c,sampleRate:d,objectType:f,channelCount:h,codec:g,config:m,originCodec:"mp4a.40.".concat(f)}}}},{key:"parseAudioSpecificConfig",value:function(t){if(t.length){var n=t[0]>>>3,r=(7&t[0])<<1|t[1]>>>7,i=(120&t[1])>>>3,a=e.FREQ[r];if(a){var s=e._getConfig(r,i,n);return{samplingFrequencyIndex:r,sampleRate:a,objectType:n,channelCount:i,config:s.config,codec:s.codec,originCodec:"mp4a.40.".concat(n)}}}}},{key:"getFrameDuration",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:9e4;return 1024*t/e}},{key:"_getConfig",value:function(e,t,n){var r,i,a=[];return cV?e>=6?(r=5,i=e-3):(r=2,i=e):cH?(r=2,i=e):(r=5,i=e,e>=6?i=e-3:1===t&&(r=2,i=e)),a[0]=r<<3,a[0]|=(14&e)>>1,a[1]=(1&e)<<7,a[1]|=t<<3,5===r&&(a[1]|=(14&i)>>1,a[2]=(1&i)<<7,a[2]|=8,a[3]=0),{config:a,codec:"mp4a.40.".concat(r)}}},{key:"getSilentFrame",value:function(e,t){if("mp4a.40.2"===e){if(1===t)return new Uint8Array([0,200,0,128,35,128]);if(2===t)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224])}else{if(1===t)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===t||3===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}}}]),e}();cy(cW,"FREQ",[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350]);var cq=function(){function e(){cv(this,e)}return cg(e,null,[{key:"getFrameDuration",value:function(e){return 20}},{key:"parseHeaderPackets",value:function(e){if(e.length){for(var t=new DataView(e.buffer,e.byteOffset,e.byteLength),n="",r=0;r<8;r++)n+=String.fromCodePoint(e[r]);if("OpusHead"!==n)throw Error("Invalid Opus MagicSignature");var i=e[9];console.log("Pre-skip",e[10],e[11]);var a=t.getUint32(12,!0),s=t.getInt16(16,!0);if(a)return{outputGain:s,sampleRate:a,channelCount:i,config:new Uint8Array(e.buffer,e.byteOffset+8,e.byteLength-8),codec:"opus",originCodec:"opus"}}}}]),e}(),cK=function(){function e(t,n,r){cv(this,e),this.videoTrack=t,this.audioTrack=n,this.metadataTrack=r,this._baseDts=-1,this._baseDtsInited=!1,this._audioNextPts=void 0,this._videoNextDts=void 0,this._audioTimestampBreak=0,this._videoTimestampBreak=0,this._lastVideoDuration=0,this._keyFrameInNextChunk=!1,this._lastAudioExceptionGapDot=-1/0,this._lastAudioExceptionOverlapDot=-1/0,this._lastAudioExceptionLargeGapDot=-1/0,this._lastVideoExceptionLargeGapDot=-1/0,this._lastVideoExceptionChunkFirstDtsDot=-1/0}return cg(e,[{key:"fix",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=!(arguments.length>2)||void 0===arguments[2]||arguments[2];t=Math.round(1e3*t);var i=this.videoTrack,a=this.audioTrack;if((n||!r)&&(this._videoLastSample=null,this._audioNextPts=void 0,this._videoNextDts=void 0,this._audioTimestampBreak=0,this._videoTimestampBreak=0,this._lastAudioExceptionGapDot=-1/0,this._lastAudioExceptionOverlapDot=-1/0,this._lastAudioExceptionLargeGapDot=-1/0,this._lastVideoExceptionLargeGapDot=-1/0,this._lastVideoExceptionChunkFirstDtsDot=-1/0),n&&!r&&(this._baseDtsInited=!1),this._baseDtsInited||this._calculateBaseDts(a,i),!r&&t&&(this._audioNextPts=this._videoNextDts=t),this._baseDtsInited&&(this._videoTimestampBreak||!this.videoTrack.exist())&&(this._audioTimestampBreak||!this.audioTrack.exist())&&this._resetBaseDtsWhenStreamBreaked(),this._fixAudio(a),this._keyFrameInNextChunk=!1,this._fixVideo(i),this.metadataTrack.exist()){var s=this.metadataTrack.timescale;this.metadataTrack.seiSamples.forEach(function(t){t.pts=t.originPts-e._baseDts,t.time=Math.max(0,t.pts)/s}),this.metadataTrack.flvScriptSamples.forEach(function(t){t.pts=t.originPts-e._baseDts,t.time=Math.max(0,t.pts)/s})}i.samples.length&&(i.baseMediaDecodeTime=i.samples[0].dts),a.samples.length&&(a.baseMediaDecodeTime=a.samples[0].pts*a.timescale/1e3)}},{key:"_fixVideo",value:function(e){var t,n,r=this,i=e.samples;if(i.length){if(i.forEach(function(e){e.dts-=r._baseDts,e.pts-=r._baseDts,e.keyframe&&(r._keyFrameInNextChunk=!0)}),e.fpsNum&&e.fpsDen)t=e.timescale*(e.fpsDen/e.fpsNum);else if(e.length>1){var a=e.samples[0];t=Math.floor((e.samples[i.length-1].dts-a.dts)/(i.length-1))}else t=this._lastVideoDuration||40;var s=i.pop();if(this._videoLastSample&&i.unshift(this._videoLastSample),this._videoLastSample=s,i.length){if(void 0===this._videoNextDts){var l=i[0];this._videoNextDts=l.dts}var u=i.length,c=0,d=i[0],f=this._videoNextDts-d.dts;Math.abs(f)>200&&(Math.abs(d.dts-this._lastVideoExceptionChunkFirstDtsDot)>5e3&&(this._lastVideoExceptionChunkFirstDtsDot=d.dts,e.warnings.push({type:cI.LARGE_VIDEO_GAP_BETWEEN_CHUNK,nextDts:this._videoNextDts,firstSampleDts:d.dts,nextSampleDts:null==(n=i[1])?void 0:n.dts,sampleDuration:f})),this._videoTimestampBreak>=5?(this._videoNextDts=d.dts,this._videoTimestampBreak=0):(d.dts+=f,d.pts+=f,this.audioTrack.exist()||(this._videoTimestampBreak=1)));for(var h=0;h<u;h++){var p=i[h].dts,m=i[h+1];((c=h<u-1?m.dts-p:s?s.dts-p:t)>1e3||c<0)&&(this._videoTimestampBreak++,Math.abs(p-this._lastVideoExceptionLargeGapDot)>5e3&&(this._lastVideoExceptionLargeGapDot=p,e.warnings.push({type:cI.LARGE_VIDEO_GAP,time:p/e.timescale,dts:p,originDts:i[h].originDts,nextDts:this._videoNextDts,sampleDuration:c,refSampleDuration:t})),c=t),i[h].duration=c,this._videoNextDts+=c,this._lastVideoDuration=c}}}}},{key:"_fixAudio",value:function(e){var t=this,n=e.samples;n.length&&(n.forEach(function(e){e.dts=e.pts-=t._baseDts}),this._doFixAudioInternal(e,n,1e3))}},{key:"_calculateBaseDts",value:function(e,t){var n=e.samples,r=t.samples;if(!n.length&&!r.length)return!1;var i=1/0,a=1/0;n.length&&(e.baseDts=i=n[0].pts),r.length&&(t.baseDts=a=r[0].dts),this._baseDts=Math.min(i,a);var s=a-i;return Number.isFinite(s)&&Math.abs(s)>500&&t.warnings.push({type:cI.LARGE_AV_SHIFT,videoBaseDts:a,audioBasePts:i,baseDts:this._baseDts,delta:s}),this._baseDtsInited=!0,!0}},{key:"_resetBaseDtsWhenStreamBreaked",value:function(){this._calculateBaseDts(this.audioTrack,this.videoTrack)&&(this.audioTrack.exist()?this.videoTrack.exist()?this._baseDts-=Math.min(this._audioNextPts,this._videoNextDts):this._baseDts-=this._audioNextPts:this._baseDts-=this._videoNextDts,this._videoTimestampBreak=0,this._audioTimestampBreak=0)}},{key:"_doFixAudioInternal",value:function(e,t,n){if(!e.sampleDuration)switch(e.codecType){case cC.AAC:e.sampleDuration=cW.getFrameDuration(e.timescale,n);break;case cC.OPUS:e.sampleDuration=cq.getFrameDuration(e.samples,n);break;case cC.G711PCMA:case cC.G711PCMU:e.sampleDuration=this._getG711Duration(e);break;default:console.error("can't fix audio codecType:",e.codecType)}var r=e.sampleDuration,i=e.codecType===cC.OPUS?20:e.codecType===cC.AAC?1024:r*e.timescale/1e3;if(void 0===this._audioNextPts){var a=t[0];this._audioNextPts=a.pts}for(var s=0;s<t.length;s++){var l=this._audioNextPts,u=t[s],c=u.pts-l;if(0===s&&this._audioTimestampBreak>=5&&this._keyFrameInNextChunk&&(l=this._audioNextPts=u.dts,c=0,this._audioTimestampBreak=0),!this._audioTimestampBreak&&c>=3*r&&c<=1e3&&!cG){var d=this._getSilentFrame(e)||t[0].data.subarray(),f=Math.floor(c/r);Math.abs(u.pts-this._lastAudioExceptionGapDot)>5e3&&(this._lastAudioExceptionGapDot=u.pts,e.warnings.push({type:cI.AUDIO_FILLED,pts:u.pts,originPts:u.originPts,count:f,nextPts:l,refSampleDuration:r}));for(var h=0;h<f;h++){var p=new cL(Math.floor(this._audioNextPts+r)-Math.floor(this._audioNextPts),d,i);p.originPts=Math.floor(this._baseDts+l),t.splice(s,0,p),this._audioNextPts+=r,s++}s--}else if(c<=-3*r&&c>=-1e3)Math.abs(u.pts-this._lastAudioExceptionOverlapDot)>5e3&&(this._lastAudioExceptionOverlapDot=u.pts,e.warnings.push({type:cI.AUDIO_DROPPED,pts:u.pts,originPts:u.originPts,nextPts:l,refSampleDuration:r})),t.splice(s,1),s--;else{if(Math.abs(c)>1e3&&(this._audioTimestampBreak++,Math.abs(u.pts-this._lastAudioExceptionLargeGapDot)>5e3&&(this._lastAudioExceptionLargeGapDot=u.pts,e.warnings.push({type:cI.LARGE_AUDIO_GAP,time:u.pts/1e3,pts:u.pts,originPts:u.originPts,nextPts:l,sampleDuration:c,refSampleDuration:r}))),e.codecType===cC.OPUS){var m=t[t.length-1];m&&(m.duration=u.pts-m.pts)}else u.dts=u.pts=l,u.duration=i;this._audioNextPts+=r}}}},{key:"_getG711Duration",value:function(e){var t=e.sampleSize,n=e.channelCount,r=e.sampleRate,i=e.samples[0];if(i)return 2*i.data.byteLength/n/(t/8)/r*1e3}},{key:"_getSilentFrame",value:function(e){return e.codecType===cC.AAC?cW.getSilentFrame(e.codec,e.channelCount):new Uint8Array(8*e.sampleDuration*e.channelCount)}}]),e}();function cJ(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=new Uint8Array((t=t.filter(Boolean)).reduce(function(e,t){return e+t.byteLength},0)),i=0;return t.forEach(function(e){r.set(e,i),i+=e.byteLength}),r}function cZ(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(e[t]<<24>>>0)+(e[t+1]<<16)+(e[t+2]<<8)+(e[t+3]||0)}function c$(e){if(!Array.isArray(e)){for(var t=[],n="",r=0;r<e.length;r++)r%2&&(t.push(parseInt(n=e[r-1]+e[r],16)),n="");return t}return e.map(function(e){return parseInt(e,16)})}var cY=function(){function e(){cv(this,e)}return cg(e,null,[{key:"parseAnnexB",value:function(e){var t=e.byteLength-1,n=0;do{if(0===e[t])n++;else break;t--}while(t>0);n>=3&&(e=e.subarray(0,t+1));for(var r=e.length,i=2,a=0;null!==e[i]&&void 0!==e[i]&&1!==e[i];)i++;if((a=++i+2)>=r)return[];for(var s=[];a<r;)switch(e[a]){case 0:if(0!==e[a-1]){a+=2;break}if(0!==e[a-2]){a++;break}if(a<r-1&&1!==e[a+1]){a++;break}i!==a-2&&s.push(e.subarray(i,a-2));do a++;while(1!==e[a]&&a<r);a=(i=a+1)+2;break;case 1:if(0!==e[a-1]||0!==e[a-2]){a+=3;break}i!==a-2&&s.push(e.subarray(i,a-2)),a=(i=a+1)+2;break;default:a+=3}return i<r&&s.push(e.subarray(i)),s}},{key:"parseAvcC",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4;if(!(e.length<4)){for(var r=e.length,i=[],a=0;a+n<r;)if(t=cZ(e,a),3===n&&(t>>>=8),a+=n,t){if(a+t>r)break;i.push(e.subarray(a,a+t)),a+=t}return i}}},{key:"parseSEI",value:function(e,t){for(var n=e.length,r=t?2:1,i=0,a=0,s="";255===e[r];)i+=255,r++;for(i+=e[r++];255===e[r];)a+=255,r++;if(a+=e[r++],5===i&&n>r+16)for(var l=0;l<16;l++)s+=e[r].toString(16),r++;return{payload:e.subarray(r,r+a),type:i,size:a,uuid:s}}},{key:"removeEPB",value:function(e){for(var t=e.byteLength,n=[],r=1;r<t-2;)0===e[r]&&0===e[r+1]&&3===e[r+2]?(n.push(r+2),r+=2):r++;if(!n.length)return e;var i=t-n.length,a=new Uint8Array(i),s=0;for(r=0;r<i;s++,r++)s===n[0]&&(s++,n.shift()),a[r]=e[s];return a}}]),e}(),cQ=function(){function e(t){if(cv(this,e),cy(this,"_bytesAvailable",void 0),cy(this,"_bitsAvailable",0),cy(this,"_word",0),!t)throw Error("ExpGolomb data params is required");this._data=t,this._bytesAvailable=t.byteLength,this._bytesAvailable&&this._loadWord()}return cg(e,[{key:"bitsAvailable",get:function(){return this._bitsAvailable}},{key:"_loadWord",value:function(){var e=this._data.byteLength-this._bytesAvailable,t=Math.min(4,this._bytesAvailable);if(0===t)throw Error("No bytes available");var n=new Uint8Array(4);n.set(this._data.subarray(e,e+t)),this._word=new DataView(n.buffer).getUint32(0),this._bitsAvailable=8*t,this._bytesAvailable-=t}},{key:"skipBits",value:function(e){if(this._bitsAvailable>e)this._word<<=e,this._bitsAvailable-=e;else{var t=Math.floor((e-=this._bitsAvailable)/8);e-=8*t,this._bytesAvailable-=t,this._loadWord(),this._word<<=e,this._bitsAvailable-=e}}},{key:"readBits",value:function(e){if(e>32)throw Error("Cannot read more than 32 bits");var t=Math.min(this._bitsAvailable,e),n=this._word>>>32-t;return(this._bitsAvailable-=t,this._bitsAvailable>0?this._word<<=t:this._bytesAvailable>0&&this._loadWord(),(t=e-t)>0&&this._bitsAvailable)?n<<t|this.readBits(t):n}},{key:"skipLZ",value:function(){var e;for(e=0;e<this._bitsAvailable;++e)if((this._word&0x80000000>>>e)!=0)return this._word<<=e,this._bitsAvailable-=e,e;return this._loadWord(),e+this.skipLZ()}},{key:"skipUEG",value:function(){this.skipBits(1+this.skipLZ())}},{key:"readUEG",value:function(){var e=this.skipLZ();return this.readBits(e+1)-1}},{key:"readEG",value:function(){var e=this.readUEG();return 1&e?1+e>>>1:-1*(e>>>1)}},{key:"readBool",value:function(){return 1===this.readBits(1)}},{key:"readUByte",value:function(){return this.readBits(8)}},{key:"skipScalingList",value:function(e){for(var t=8,n=8,r=0;r<e;r++)0!==n&&(n=(t+this.readEG()+256)%256),t=0===n?t:n}}]),e}(),cX=function(){function e(){cv(this,e)}return cg(e,null,[{key:"parseAVCDecoderConfigurationRecord",value:function(t){if(!(t.length<7)){for(var n,r,i,a=(3&t[4])+1,s=[],l=[],u=6,c=31&t[5],d=0;d<c;d++)if(r=t[u]<<8|t[u+1],u+=2,r){var f=t.subarray(u,u+r);u+=r,s.push(f),n||(n=e.parseSPS(cY.removeEPB(f)))}var h=t[u];u++;for(var p=0;p<h;p++)i=t[u]<<8|t[u+1],u+=2,i&&(l.push(t.subarray(u,u+i)),u+=i);return{sps:n,spsArr:s,ppsArr:l,nalUnitSize:a}}}},{key:"parseSPS",value:function(e){var t,n,r,i,a,s=new cQ(e);s.readUByte();var l=s.readUByte(),u=s.readUByte(),c=s.readUByte();s.skipUEG();var d=420;if(100===l||110===l||122===l||244===l||44===l||83===l||86===l||118===l||128===l||138===l||144===l){var f=s.readUEG();if(f<=3&&(d=[0,420,422,444][f]),3===f&&s.skipBits(1),s.skipUEG(),s.skipUEG(),s.skipBits(1),s.readBool())for(var h=3!==f?8:12,p=0;p<h;p++)s.readBool()&&(p<6?s.skipScalingList(16):s.skipScalingList(64))}s.skipUEG();var m=s.readUEG();if(0===m)s.readUEG();else if(1===m){s.skipBits(1),s.skipUEG(),s.skipUEG();for(var g=s.readUEG(),y=0;y<g;y++)s.skipUEG()}s.skipUEG(),s.skipBits(1);var _=s.readUEG(),b=s.readUEG(),w=s.readBits(1);0===w&&s.skipBits(1),s.skipBits(1);var x=0,k=0,S=0,E=0;if(s.readBool()&&(x=s.readUEG(),k=s.readUEG(),S=s.readUEG(),E=s.readUEG()),s.readBool()){if(s.readBool())switch(s.readUByte()){case 1:t=[1,1];break;case 2:t=[12,11];break;case 3:t=[10,11];break;case 4:t=[16,11];break;case 5:t=[40,33];break;case 6:t=[24,11];break;case 7:t=[20,11];break;case 8:t=[32,11];break;case 9:t=[80,33];break;case 10:t=[18,11];break;case 11:t=[15,11];break;case 12:t=[64,33];break;case 13:t=[160,99];break;case 14:t=[4,3];break;case 15:t=[3,2];break;case 16:t=[2,1];break;case 255:t=[s.readUByte()<<8|s.readUByte(),s.readUByte()<<8|s.readUByte()]}if(s.readBool()&&s.readBool(),s.readBool()&&(s.readBits(4),s.readBool()&&s.readBits(24)),s.readBool()&&(s.readUEG(),s.readUEG()),s.readBool()){var T=s.readBits(32),A=s.readBits(32);n=s.readBool(),a=(r=A)/(i=2*T)}}return{codec:function(e){for(var t,n="avc1.",r=0;r<3;r++)(t=e[r].toString(16)).length<2&&(t="0".concat(t)),n+=t;return n}(e.subarray(1,4)),profileIdc:l,profileCompatibility:u,levelIdc:c,chromaFormat:d,width:Math.ceil((_+1)*16-2*(x+k)),height:(2-w)*(b+1)*16-(w?2:4)*(S+E),sarRatio:t,fpsNum:r,fpsDen:i,fps:a,fixedFrame:n}}}]),e}(),c0=function(){function e(){cv(this,e)}return cg(e,null,[{key:"parseHEVCDecoderConfigurationRecord",value:function(t){var n,r,i,a,s,l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!(t.length<23)){l=l||{};for(var u=(3&t[21])+1,c=[],d=[],f=[],h=23,p=t[22],m=0;m<p;m++){i=63&t[h],a=t[h+1]<<8|t[h+2],h+=3;for(var g=0;g<a;g++)if(s=t[h]<<8|t[h+1],h+=2,s){switch(i){case 32:var y=t.subarray(h,h+s);n||(n=e.parseVPS(cY.removeEPB(y),l)),f.push(y);break;case 33:var _=t.subarray(h,h+s);r||(r=e.parseSPS(cY.removeEPB(_),l)),c.push(_);break;case 34:d.push(t.subarray(h,h+s))}h+=s}}return{hvcC:l,sps:r,spsArr:c,ppsArr:d,vpsArr:f,nalUnitSize:u}}}},{key:"parseVPS",value:function(t,n){n=n||{};var r=new cQ(t);r.readUByte(),r.readUByte(),r.readBits(12);var i=r.readBits(3);return n.numTemporalLayers=Math.max(n.numTemporalLayers||0,i+1),r.readBits(17),e._parseProfileTierLevel(r,i,n),n}},{key:"parseSPS",value:function(t){var n,r,i,a,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};s=s||{};var l=new cQ(t);l.readUByte(),l.readUByte(),l.readBits(4);var u=l.readBits(3);s.numTemporalLayers=Math.max(u+1,s.numTemporalLayers||0),s.temporalIdNested=l.readBits(1),e._parseProfileTierLevel(l,u,s),l.readUEG();var c=s.chromaFormatIdc=l.readUEG(),d=420;c<=3&&(d=[0,420,422,444][c]);var f=0;3===c&&(f=l.readBits(1));var h=l.readUEG(),p=l.readUEG(),m=l.readBits(1);if(1===m&&(n=l.readUEG(),r=l.readUEG(),i=l.readUEG(),a=l.readUEG()),s.bitDepthLumaMinus8=l.readUEG(),s.bitDepthChromaMinus8=l.readUEG(),1===m){var g=(1===c||2===c)&&0===f?2:1,y=1===c&&0===f?2:1;h-=g*(r+n),p-=y*(a+i)}return{codec:"hev1.1.6.L93.B0",width:h,height:p,chromaFormat:d,hvcC:s}}},{key:"_parseProfileTierLevel",value:function(e,t,n){var r=n.generalTierFlag||0;n.generalProfileSpace=e.readBits(2),n.generalTierFlag=Math.max(e.readBits(1),r),n.generalProfileIdc=Math.max(e.readBits(5),n.generalProfileIdc||0),n.generalProfileCompatibilityFlags=e.readBits(32),n.generalConstraintIndicatorFlags=[e.readBits(8),e.readBits(8),e.readBits(8),e.readBits(8),e.readBits(8),e.readBits(8)];var i=e.readBits(8);r<n.generalTierFlag?n.generalLevelIdc=i:n.generalLevelIdc=Math.max(i,n.generalLevelIdc||0);var a=[],s=[];if(t>e.bitsAvailable)throw Error("maxSubLayersMinus inavlid size ".concat(t));for(var l=0;l<t;l++)a[l]=e.readBits(1),s[l]=e.readBits(1);t>0&&e.readBits((8-t)*2);for(var u=0;u<t;u++)0!==a[u]&&(e.readBits(2),e.readBits(1),e.readBits(5),e.readBits(16),e.readBits(16),e.readBits(4),e.readBits(16),e.readBits(16),e.readBits(12)),0!==s[u]&&e.readBits(8)}}]),e}(),c1=function(){function e(){cv(this,e)}return cg(e,null,[{key:"decode",value:function(t){for(var n=[],r=0,i=t.length;r<i;){if(t[r]<128){n.push(String.fromCharCode(t[r])),++r;continue}if(t[r]<192);else if(t[r]<224){if(e._checkContinuation(t,r,1)){var a=(31&t[r])<<6|63&t[r+1];if(a>=128){n.push(String.fromCharCode(65535&a)),r+=2;continue}}}else if(t[r]<240){if(e._checkContinuation(t,r,2)){var s=(15&t[r])<<12|(63&t[r+1])<<6|63&t[r+2];if(s>=2048&&(63488&s)!=55296){n.push(String.fromCharCode(65535&s)),r+=3;continue}}}else if(t[r]<248&&e._checkContinuation(t,r,3)){var l=(7&t[r])<<18|(63&t[r+1])<<12|(63&t[r+2])<<6|63&t[r+3];if(l>65536&&l<1114112){l-=65536,n.push(String.fromCharCode(l>>>10|55296)),n.push(String.fromCharCode(1023&l|56320)),r+=4;continue}}n.push(String.fromCharCode(65533)),++r}return n.join("")}},{key:"_checkContinuation",value:function(e,t,n){if(!(t+n<e.length))return!1;for(;n--;)if((192&e[++t])!=128)return!1;return!0}}]),e}(),c2=function(){function e(){cv(this,e)}return cg(e,null,[{key:"parse",value:function(t){if(!(t.length<3)){var n={},r=e._parseValue(new DataView(t.buffer,t.byteOffset,t.byteLength)),i=e._parseValue(new DataView(t.buffer,t.byteOffset+r.size,t.byteLength-r.size));return n[r.data]=i.data,n}}},{key:"_parseValue",value:function(t){var n,r=t.byteLength,i=t.getUint8(0),a=1,s=!1;switch(i){case 0:n=t.getFloat64(1),a+=8;break;case 1:n=!!t.getUint8(1),a+=1;break;case 2:var l=e._parseString(new DataView(t.buffer,t.byteOffset+a,t.byteLength-a)),u=l.data,c=l.size;n=u,a+=c;break;case 3:n={};var d=0;for((0xffffff&t.getUint32(r-4))==9&&(d=3);a<r-4;){var f=e._parseObject(new DataView(t.buffer,t.byteOffset+a,t.byteLength-a-d)),h=f.size,p=f.data;if(f.isEnd)break;n[p.name]=p.value,a+=h}a<=r-3&&9==(0xffffff&t.getUint32(a-1))&&(a+=3);break;case 8:n={},a+=4;var m=0;for((0xffffff&t.getUint32(r-4))==9&&(m=3);a<r-8;){var g=e._parseObject(new DataView(t.buffer,t.byteOffset+a,t.byteLength-a-m)),y=g.size,_=g.data;if(g.isEnd)break;n[_.name]=_.value,a+=y}a<=r-3&&9==(0xffffff&t.getUint32(a-1))&&(a+=3);break;case 9:n=void 0,a=1,s=!0;break;case 10:n=[];var b=t.getUint32(1);a+=4;for(var w=0;w<b;w++){var x=e._parseValue(new DataView(t.buffer,t.byteOffset+a,t.byteLength-a)),k=x.data,S=x.size;n.push(k),a+=S}break;case 11:n=new Date(t.getFloat64(a)+6e4*t.getInt16(a+8)),a+=10;break;case 12:var E=t.getUint32(1);a+=4,n="",E>0&&(n=c1.decode(new Uint8Array(t.buffer,t.byteOffset+a,E))),a+=E;break;default:a=r}return{data:n,size:a,isEnd:s}}},{key:"_parseString",value:function(e){var t=e.getUint16(0),n="";return t>0&&(n=c1.decode(new Uint8Array(e.buffer,e.byteOffset+2,t))),{data:n,size:2+t}}},{key:"_parseObject",value:function(t){if(!(t.byteLength<3)){var n=e._parseString(t),r=e._parseValue(new DataView(t.buffer,t.byteOffset+n.size,t.byteLength-n.size));return{data:{name:n.data,value:r.data},size:n.size+r.size,isEnd:r.isEnd}}}}]),e}(),c5={G711A:7,G711M:8,AAC:10,OPUS:13},c3=new cF("FlvDemuxer"),c6=function(){function e(t,n,r){cv(this,e),cy(this,"_headerParsed",!1),cy(this,"_remainingData",null),cy(this,"_gopId",0),cy(this,"_needAddMetaBeforeKeyFrameNal",!0),this.videoTrack=t||new cD,this.audioTrack=n||new cR,this.metadataTrack=r||new cN,this._fixer=new cK(this.videoTrack,this.audioTrack,this.metadataTrack)}return cg(e,[{key:"demux",value:function(t){var n,r,i,a,s,l,u=arguments.length>1&&void 0!==arguments[1]&&arguments[1],c=!(arguments.length>2)||void 0===arguments[2]||arguments[2],d=arguments.length>3?arguments[3]:void 0,f=this.audioTrack,h=this.videoTrack,p=this.metadataTrack;if((u||!c)&&(this._remainingData=null),u&&(this._headerParsed=!1),u?(h.reset(),f.reset(),p.reset()):(h.samples=[],f.samples=[],p.seiSamples=[],p.flvScriptSamples=[],h.warnings=[],f.warnings=[],this._remainingData&&(t=cJ(this._remainingData,t),this._remainingData=null)),!t.length)return{videoTrack:h,audioTrack:f,metadataTrack:p};var m=0;if(!this._headerParsed){if(!e.probe(t))throw Error("Invalid flv file");f.present=(4&t[4])>>>2!=0,h.present=(1&t[4])!=0,this._headerParsed=!0,m=cZ(t,5)+4}for(var g=t.length;m+15<g&&(r=t[m],i=t[m+1]<<16|t[m+2]<<8|t[m+3],!(m+15+i>g));)a=(t[m+7]<<24>>>0)+(t[m+4]<<16)+(t[m+5]<<8)+t[m+6],m+=11,s=t.subarray(m,m+i),8===r?this._parseAudio(s,a):9===r?(d&&(this.seamlessLoadingSwitching=!0),this._parseVideo(s,a)):18===r?this._parseScript(s,a):c3.warn("Invalid tag type: ".concat(r)),m+=i,(l=cZ(t,m))!==11+i&&c3.warn("Invalid PrevTagSize ".concat(l," (").concat(11+i,")")),m+=4;m<g&&(this._remainingData=t.subarray(m)),f.formatTimescale=h.formatTimescale=h.timescale=p.timescale=1e3,f.timescale=f.codecType===cC.OPUS?1e3:f.sampleRate||0,!f.exist()&&f.hasSample()&&f.reset(),!h.exist()&&h.hasSample()&&h.reset();var y=p.flvScriptSamples[p.flvScriptSamples.length-1],_=null==y||null==(n=y.data)?void 0:n.onMetaData;return _&&(null!=h&&h.exist()&&(_.hasOwnProperty("duration")&&(h.duration=1e3*_.duration),_.hasOwnProperty("width")&&_.hasOwnProperty("height")&&(h.width=_.width,h.height=_.height)),null!=f&&f.exist()&&_.hasOwnProperty("duration")&&(f.duration=1e3*_.duration)),{videoTrack:h,audioTrack:f,metadataTrack:p}}},{key:"fix",value:function(e,t,n){return this._fixer.fix(e,t,n),{videoTrack:this.videoTrack,audioTrack:this.audioTrack,metadataTrack:this.metadataTrack}}},{key:"demuxAndFix",value:function(e,t,n,r,i){return this.demux(e,t,n,i),this.fix(r,t,n)}},{key:"_parseAudio",value:function(t,n){if(t.length){var r=(240&t[0])>>>4,i=this.audioTrack;if(r!==c5.AAC&&r!==c5.G711A&&r!==c5.G711M&&r!==c5.OPUS){c3.warn("Unsupported sound format: ".concat(r)),i.reset();return}if(r!==c5.AAC&&r!==c5.OPUS){var a=(12&t[0])>>2,s=(2&t[0])>>1,l=1&t[0];i.sampleRate=e.AUDIO_RATE[a],i.sampleSize=s?16:8,i.channelCount=l+1}switch(r){case c5.G711A:case c5.G711M:this._parseG711(t,n,r);break;case c5.AAC:this._parseAac(t,n);break;case c5.OPUS:this._parseOpus(t,n)}}}},{key:"_parseOpus",value:function(e,t){var n=this.audioTrack,r=e[1];switch(n.codecType=cC.OPUS,r){case 0:var i=cq.parseHeaderPackets(e.subarray(2));i?(n.codec=i.codec,n.channelCount=i.channelCount,n.sampleRate=i.sampleRate,n.config=i.config,n.sampleDuration=cq.getFrameDuration([],n.timescale)):(n.reset(),c3.warn("Cannot parse AudioSpecificConfig",e));break;case 1:if(null==t)return;var a=new cL(t,e.subarray(2),n.sampleDuration);n.samples.push(a);break;default:c3.warn("Unknown OpusPacketType: ".concat(r))}}},{key:"_parseG711",value:function(e,t,n){var r=this.audioTrack,i=e.subarray(1);if(!(i.byteLength<1)){var a=new cL(t,i);r.codecType=7===n?cC.G711PCMA:cC.G711PCMU,r.sampleRate=8e3,r.codec=r.codecType,r.samples.push(a)}}},{key:"_parseAac",value:function(e,t){var n=this.audioTrack;if(n.codecType=cC.AAC,0===e[1]){var r=cW.parseAudioSpecificConfig(e.subarray(2));r?(n.codec=r.codec,n.channelCount=r.channelCount,n.sampleRate=r.sampleRate,n.config=r.config,n.objectType=r.objectType,n.sampleRateIndex=r.samplingFrequencyIndex):(n.reset(),c3.warn("Cannot parse AudioSpecificConfig",e))}else if(1===e[1]){if(null==t)return;n.samples.push(new cL(t,e.subarray(2)))}else c3.warn("Unknown AACPacketType: ".concat(e[1]))}},{key:"_parseVideo",value:function(e,t){var n=this;if(!(e.length<6)){var r=(240&e[0])>>>4,i=15&e[0],a=this.videoTrack;if(7!==i&&12!==i){a.reset(),c3.warn("Unsupported codecId: ".concat(i));return}var s=12===i;a.codecType=s?cO.HEVC:cO.AVC;var l=e[1],u=(e[2]<<16|e[3]<<8|e[4])<<8>>8;if(0===l){var c=e.subarray(5),d=s?c0.parseHEVCDecoderConfigurationRecord(c):cX.parseAVCDecoderConfigurationRecord(c);if(d){var f=d.hvcC,h=d.sps,p=d.ppsArr,m=d.spsArr,g=d.vpsArr,y=d.nalUnitSize;f&&(a.hvcC=a.hvcC||f),h&&(a.codec=h.codec,a.width=h.width,a.height=h.height,a.sarRatio=h.sarRatio,a.fpsNum=h.fpsNum,a.fpsDen=h.fpsDen),m.length&&(a.sps=m),p.length&&(a.pps=p),g&&g.length&&(a.vps=g),y&&(a.nalUnitSize=y)}else c3.warn("Cannot parse ".concat(s?"HEVC":"AVC","DecoderConfigurationRecord"),e)}else if(1===l){var _=cY.parseAvcC(e.subarray(5),a.nalUnitSize);if((_=this._checkAddMetaNalToUnits(s,_,a))&&_.length){var b=new cU(t+u,t,_);if(this.seamlessLoadingSwitching&&t<a.lastKeyFrameDts)return;this.seamlessLoadingSwitching=!1,1===r&&(b.setToKeyframe(),a.lastKeyFrameDts=t),a.samples.push(b),_.forEach(function(e){var r=s?e[0]>>>1&63:31&e[0];switch(r){case 5:case 16:case 17:case 18:case 19:case 20:case 21:case 22:case 23:if(!s&&5!==r||s&&5===r)break;b.setToKeyframe();break;case 6:case 39:case 40:if(!s&&6!==r||s&&6===r)break;n.metadataTrack.seiSamples.push(new cM(cY.parseSEI(cY.removeEPB(e),s),t+u))}}),b.keyframe&&this._gopId++,b.gopId=this._gopId}else c3.warn("Cannot parse NALUs",e)}else 2===l||c3.warn("Unknown AVCPacketType: ".concat(l))}}},{key:"_checkAddMetaNalToUnits",value:function(e,t,n){return!e||!this._needAddMetaBeforeKeyFrameNal||t.map(function(e){return e[0]>>>1&63}).includes(32)?(this._needAddMetaBeforeKeyFrameNal=!1,t):(t.unshift(n.pps[0]),t.unshift(n.sps[0]),t.unshift(n.vps[0]),t.filter(Boolean))}},{key:"_parseScript",value:function(e,t){this.metadataTrack.flvScriptSamples.push(new cB(c2.parse(e),t))}}],[{key:"probe",value:function(e){return 70===e[0]&&76===e[1]&&86===e[2]&&1===e[3]&&cZ(e,5)>=9}}]),e}();cy(c6,"AUDIO_RATE",[5500,11e3,22e3,44e3]);var c4=function(){function e(){cv(this,e),this.buffer=new Uint8Array(0)}return cg(e,[{key:"write",value:function(){for(var e=this,t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];n.forEach(function(t){t?e.buffer=function(e){for(var t=0,n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];r.forEach(function(e){t+=e.length});var a=new e(t),s=0;return r.forEach(function(e){a.set(e,s),s+=e.length}),a}(Uint8Array,e.buffer,t):window.console.warn(t)})}}],[{key:"writeUint16",value:function(e){return new Uint8Array([e>>8&255,255&e])}},{key:"writeUint32",value:function(e){return new Uint8Array([e>>24,e>>16&255,e>>8&255,255&e])}}]),e}(),c8=function(){function e(){cv(this,e)}return cg(e,null,[{key:"box",value:function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=8+(n=n.filter(Boolean)).reduce(function(e,t){return e+t.byteLength},0),a=new Uint8Array(i);a[0]=i>>24&255,a[1]=i>>16&255,a[2]=i>>8&255,a[3]=255&i,a.set(e,4);var s=8;return n.forEach(function(e){a.set(e,s),s+=e.byteLength}),a}},{key:"ftyp",value:function(t){return t.find(function(e){return e.type===cA.VIDEO&&e.codecType===cO.HEVC})?e.FTYPHEV1:e.FTYPAVC1}},{key:"initSegment",value:function(t){return cJ(e.ftyp(t),e.moov(t))}},{key:"pssh",value:function(t){var n=new Uint8Array([1,0,0,0].concat([16,119,239,236,192,178,77,2,172,227,60,30,82,226,251,75],[0,0,0,1],c$(t.kid),[0,0,0,0]));return e.box(e.types.pssh,n)}},{key:"moov",value:function(t){if(!t[0].useEME||!t[0].encv&&!t[0].enca)return e.box.apply(e,[e.types.moov,e.mvhd(t[0].mvhdDurtion||t[0].duration,t[0].mvhdTimecale||t[0].timescale)].concat(ck(t.map(function(t){return e.trak(t)})),[e.mvex(t)]));t[0].pssh||(t[0].pssh={kid:t[0].kid});var n=this.pssh(t[0].pssh);return e.box.apply(e,[e.types.moov,e.mvhd(t[0].mvhdDurtion||t[0].duration,t[0].mvhdTimecale||t[0].timescale),e.mvex(t)].concat(ck(t.map(function(t){return e.trak(t)})),[n]))}},{key:"mvhd",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:9e4;return e.box(e.types.mvhd,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,n>>24&255,n>>16&255,n>>8&255,255&n,t>>24&255,t>>16&255,t>>8&255,255&t,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]))}},{key:"trak",value:function(t){return e.box(e.types.trak,e.tkhd(t.id,t.tkhdDuration||0,t.width,t.height),e.mdia(t))}},{key:"tkhd",value:function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;return e.box(e.types.tkhd,new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,t>>24&255,t>>16&255,t>>8&255,255&t,0,0,0,0,n>>24&255,n>>16&255,n>>8&255,255&n,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,r>>8&255,255&r,0,0,i>>8&255,255&i,0,0]))}},{key:"mdia",value:function(t){return e.box(e.types.mdia,e.mdhd(t.duration,t.timescale),e.hdlr(t.type),e.minf(t))}},{key:"mdhd",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:9e4;return e.box(e.types.mdhd,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,n>>24&255,n>>16&255,n>>8&255,255&n,t>>24&255,t>>16&255,t>>8&255,255&t,85,196,0,0]))}},{key:"hdlr",value:function(t){return e.box(e.types.hdlr,e.HDLR_TYPES[t])}},{key:"minf",value:function(t){return e.box(e.types.minf,t.type===cA.VIDEO?e.VMHD:e.SMHD,e.DINF,e.stbl(t))}},{key:"stbl",value:function(t){var n=[];return t&&t.ext&&t.ext.stss&&n.push(e.stss(t.ext.stss.entries)),e.box(e.types.stbl,e.stsd(t),e.STTS,n[0],e.STSC,e.STSZ,e.STCO)}},{key:"stsd",value:function(t){var n="audio"===t.type?t.useEME&&t.enca?e.enca(t):t.codecType===cC.OPUS?e.opus(t):e.mp4a(t):t.useEME&&t.encv?e.encv(t):t.av1C?e.av01(t):e.avc1hev1(t);return e.box(e.types.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),n)}},{key:"enca",value:function(t){var n=t.enca.channelCount,r=t.enca.sampleRate,i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,n,0,16,0,0,0,0,r>>8&255,255&r,0,0]),a=e.esds(t.config),s=e.sinf(t.enca);return e.box(e.types.enca,i,a,s)}},{key:"encv",value:function(t){var n,r,i=t.sps.length>0?t.sps[0]:[],a=t.pps.length>0?t.pps[0]:[],s=t.width,l=t.height,u=t.sarRatio[0],c=t.sarRatio[1],d=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,s>>8&255,255&s,l>>8&255,255&l,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),f=new Uint8Array((n=(r=[1,i[1],i[2],i[3],255,225,i.length>>>8&255,255&i.length]).concat.apply(r,ck(i)).concat([1,a.length>>>8&255,255&a.length])).concat.apply(n,ck(a))),h=new Uint8Array([0,0,88,57,0,15,200,192,0,4,86,72]),p=e.sinf(t.encv),m=new Uint8Array([u>>24,u>>16&255,u>>8&255,255&u,c>>24,c>>16&255,c>>8&255,255&c]);return e.box(e.types.encv,d,e.box(e.types.avcC,f),e.box(e.types.btrt,h),p,e.box(e.types.pasp,m))}},{key:"schi",value:function(t){var n=new Uint8Array([]),r=e.tenc(t);return e.box(e.types.schi,n,r)}},{key:"tenc",value:function(t){var n=new Uint8Array([0,0,0,0,0,0,255&t.default_IsEncrypted,255&t.default_IV_size].concat(c$(t.default_KID)));return e.box(e.types.tenc,n)}},{key:"sinf",value:function(t){var n=new Uint8Array([]),r=new Uint8Array([t.data_format.charCodeAt(0),t.data_format.charCodeAt(1),t.data_format.charCodeAt(2),t.data_format.charCodeAt(3)]),i=new Uint8Array([0,0,0,0,99,101,110,99,0,1,0,0]),a=e.schi(t);return e.box(e.types.sinf,n,e.box(e.types.frma,r),e.box(e.types.schm,i),a)}},{key:"av01",value:function(t){return e.box(e.types.av01,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,t.width>>8&255,255&t.width,t.height>>8&255,255&t.height,0,72,0,0,0,72,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),t.av1C,t.colr)}},{key:"avc1hev1",value:function(t){var n=t.codecType===cO.HEVC,r=n?e.types.hvc1:e.types.avc1,i=n?e.hvcC(t):e.avcC(t),a=[new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,t.width>>8&255,255&t.width,t.height>>8&255,255&t.height,0,72,0,0,0,72,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),i];return n?a.push(e.box(e.types.fiel,new Uint8Array([1,0]))):t.sarRatio&&t.sarRatio.length>1&&a.push(e.pasp(t.sarRatio)),e.box.apply(e,[r].concat(a))}},{key:"avcC",value:function(t){var n,r,i,a=[],s=[];return t.sps.forEach(function(e){i=e.byteLength,a.push(i>>>8&255),a.push(255&i),a.push.apply(a,ck(e))}),t.pps.forEach(function(e){i=e.byteLength,s.push(i>>>8&255),s.push(255&i),s.push.apply(s,ck(e))}),e.box(e.types.avcC,new Uint8Array((n=(r=[1,a[3],a[4],a[5],255,224|t.sps.length]).concat.apply(r,a).concat([t.pps.length])).concat.apply(n,s)))}},{key:"hvcC",value:function(t){var n,r=t.hvcC;if(r instanceof ArrayBuffer||r instanceof Uint8Array)return r;var i=t.vps,a=t.sps,s=t.pps;if(r){var l=r.generalProfileCompatibilityFlags,u=r.generalConstraintIndicatorFlags,c=(i.length&&1)+(a.length&&1)+(s.length&&1);n=[1,r.generalProfileSpace<<6|r.generalTierFlag<<5|r.generalProfileIdc,l>>>24,l>>>16,l>>>8,l,u[0],u[1],u[2],u[3],u[4],u[5],r.generalLevelIdc,240,0,252,252|r.chromaFormatIdc,248|r.bitDepthLumaMinus8,248|r.bitDepthChromaMinus8,0,0,r.numTemporalLayers<<3|r.temporalIdNested<<2|3,c];var d=function(e){var t;n.push(e.length>>8,e.length),(t=n).push.apply(t,ck(e))};i.length&&(n.push(160,0,i.length),i.forEach(d)),a.length&&(n.push(161,0,a.length),a.forEach(d)),s.length&&(n.push(162,0,s.length),s.forEach(d))}else n=[1,1,96,0,0,0,144,0,0,0,0,0,93,240,0,252,253,248,248,0,0,15,3,160,0,1,0,24,64,1,12,1,255,255,1,96,0,0,3,0,144,0,0,3,0,0,3,0,93,153,152,9,161,0,1,0,45,66,1,1,1,96,0,0,3,0,144,0,0,3,0,0,3,0,93,160,2,128,128,45,22,89,153,164,147,43,154,128,128,128,130,0,0,3,0,2,0,0,3,0,50,16,162,0,1,0,7,68,1,193,114,180,98,64];return e.box(e.types.hvcC,new Uint8Array(n))}},{key:"pasp",value:function(t){var n=function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,a,s,l=[],u=!0,c=!1;try{a=(n=n.call(e)).next,!1;for(;!(u=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);u=!0);}catch(e){c=!0,i=e}finally{try{if(!u&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(c)throw i}}return l}}(t,2)||cS(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=n[0],i=n[1];return e.box(e.types.pasp,new Uint8Array([r>>24,r>>16&255,r>>8&255,255&r,i>>24,i>>16&255,i>>8&255,255&i]))}},{key:"mp4a",value:function(t){return e.box(e.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,t.channelCount,0,16,0,0,0,0,t.sampleRate>>8&255,255&t.sampleRate,0,0]),t.config.length?e.esds(t.config):void 0)}},{key:"esds",value:function(t){var n=t.length;return e.box(e.types.esds,new Uint8Array([0,0,0,0,3,23+n,0,0,0,4,15+n,64,21,0,6,0,0,0,218,192,0,0,218,192,5].concat([n]).concat(t).concat([6,1,2])))}},{key:"opus",value:function(t){var n=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,t.channelCount,0,16,0,0,0,0,t.sampleRate>>8&255,255&t.sampleRate,0,0]),r=t.config.length?e.dOps(t):[];return e.box(e.types.Opus,n,r)}},{key:"dOps",value:function(t){if(t.config)return t.config[4]=t.sampleRate>>>24&255,t.config[5]=t.sampleRate>>>16&255,t.config[6]=t.sampleRate>>>8&255,t.config[7]=255&t.sampleRate,e.box(e.types.dOps,t.config)}},{key:"mvex",value:function(t){return e.box.apply(e,[e.types.mvex].concat(ck(t.map(function(t){return e.trex(t.id)}))))}},{key:"trex",value:function(t){return e.box(e.types.trex,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))}},{key:"trex1",value:function(t){return e.box(e.types.trex,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t,0,0,0,1,0,0,2,0,0,0,0,0,0,1,0,0]))}},{key:"trex2",value:function(t){return e.box(e.types.trex,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t,0,0,0,1,0,0,4,0,0,0,0,0,2,0,0,0]))}},{key:"moof",value:function(t){return e.box.apply(e,[e.types.moof,e.mfhd(t[0].samples?t[0].samples[0].gopId:0)].concat(ck(t.map(function(t){return e.traf(t)}))))}},{key:"mfhd",value:function(t){return e.box(e.types.mfhd,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t]))}},{key:"traf",value:function(t){var n=e.tfhd(t.id),r=e.tfdt(t,t.baseMediaDecodeTime),i=0;if(t.isVideo&&t.videoSenc&&t.videoSenc.forEach(function(e){i+=8,e.subsamples&&e.subsamples.length&&(i+=2+6*e.subsamples.length)}),t.videoSencLength=i,t.useEME&&(t.isVideoEncryption||t.isAudioEncryption))if(t.isVideoEncryption)if(t.isVideo){var a=e.saiz(t),s=e.saio(t),l=e.trun1(t),u=e.senc(t);return e.box(e.types.traf,n,r,a,s,l,u)}else if(t.isAudioEncryption){var c=e.sbgp(),d=e.saiz(t),f=e.saio(t),h=e.senc(t),p=e.trun1(t);return e.box(e.types.traf,n,r,c,d,f,h,p)}else{var m=e.sbgp(),g=e.trun1(t);return e.box(e.types.traf,n,r,m,g)}else if(t.isVideo){var y=e.trun1(t);return e.box(e.types.traf,n,r,y)}else{var _=e.sbgp(),b=e.saiz(t),w=e.saio(t),x=e.senc(t),k=e.trun1(t);return e.box(e.types.traf,n,r,_,b,w,x,k)}var S=e.sdtp(t);return e.box(e.types.traf,n,r,S,e.trun(t.samples,S.byteLength+76))}},{key:"sdtp",value:function(t){var n=new c4;return t.samples.forEach(function(e){n.write(new Uint8Array(t.isVideo?[e.keyframe?32:16]:[16]))}),e.box(e.types.sdtp,this.extension(0,0),n.buffer)}},{key:"trun1",value:function(t){var n=new c4,r=c4.writeUint32(t.samples.length),i=null;if(t.isVideo){var a=t.videoSencLength;i=c4.writeUint32(16*t.samples.length+a+149),!t.isVideoEncryption&&t.isAudioEncryption&&(i=c4.writeUint32(16*t.samples.length+92))}else{var s=12*t.samples.length+124;t.isAudioEncryption&&(s=12*t.samples.length+8*t.audioSenc.length+177),i=c4.writeUint32(s)}return t.samples.forEach(function(e){n.write(c4.writeUint32(e.duration)),n.write(c4.writeUint32(e.size)),n.write(c4.writeUint32(e.keyframe?0x2000000:65536)),t.isVideo&&n.write(c4.writeUint32(e.cts?e.cts:0))}),e.box(e.types.trun,this.extension(0,t.flags),r,i,n.buffer)}},{key:"senc",value:function(t){var n=new c4,r=t.samples.length,i=t.isVideo?16:8,a=2*!!t.isVideo,s=[],l=0;return t.isVideo?(s=t.videoSenc,l=t.videoSencLength):s=t.audioSenc,l=l||i*r,n.write(c4.writeUint32(16+l),e.types.senc,this.extension(0,a)),n.write(c4.writeUint32(r)),s.forEach(function(e){for(var t=0;t<e.InitializationVector.length;t++)n.write(new Uint8Array([e.InitializationVector[t]]));e.subsamples&&e.subsamples.length&&(n.write(c4.writeUint16(e.subsamples.length)),e.subsamples.forEach(function(e){n.write(c4.writeUint16(e.BytesOfClearData)),n.write(c4.writeUint32(e.BytesOfProtectedData))}))}),n.buffer}},{key:"saio",value:function(t){var n=12*t.samples.length+141;!t.isVideo&&t.isAudioEncryption&&(n=149);var r=new Uint8Array([1,0,0,0,0,0,0,1,0,0,0,0,n>>24&255,n>>16&255,n>>8&255,255&n]);return e.box(e.types.saio,r)}},{key:"saiz",value:function(t){var n=t.samples.length,r=new Uint8Array([0,0,0,0,16,n>>24&255,n>>16&255,n>>8&255,255&n]);return e.box(e.types.saiz,r)}},{key:"sbgp",value:function(){var t=new Uint8Array([114,111,108,108,0,0,0,1,0,0,1,25,0,0,0,1]);return e.box(e.types.sbgp,this.extension(0,0),t)}},{key:"extension",value:function(e,t){return new Uint8Array([e,t>>16&255,t>>8&255,255&t])}},{key:"tfhd",value:function(t){return e.box(e.types.tfhd,new Uint8Array([0,0,0,0,t>>24,t>>16&255,t>>8&255,255&t]))}},{key:"tfdt",value:function(t,n){var r=Math.floor(n/0x100000000),i=Math.floor(n%0x100000000);return t.useEME&&(t.isVideoEncryption||t.isAudioEncryption)?e.box(e.types.tfdt,new Uint8Array([0,0,0,0,i>>24,i>>16&255,i>>8&255,255&i])):e.box(e.types.tfdt,new Uint8Array([1,0,0,0,r>>24,r>>16&255,r>>8&255,255&r,i>>24,i>>16&255,i>>8&255,255&i]))}},{key:"trun",value:function(t,n){var r=t.length,i=12+16*r;n+=8+i;var a=new Uint8Array(i);a.set([0,0,15,1,r>>>24&255,r>>>16&255,r>>>8&255,255&r,n>>>24&255,n>>>16&255,n>>>8&255,255&n],0);for(var s=0;s<r;s++){var l=t[s],u=l.duration,c=l.size,d=l.flag,f=void 0===d?{}:d,h=l.cts,p=void 0===h?0:h;a.set([u>>>24&255,u>>>16&255,u>>>8&255,255&u,c>>>24&255,c>>>16&255,c>>>8&255,255&c,f.isLeading<<2|(null===f.dependsOn||void 0===f.dependsOn?1:f.dependsOn),f.isDependedOn<<6|f.hasRedundancy<<4|f.paddingValue<<1|(null===f.isNonSyncSample||void 0===f.isNonSyncSample?1:f.isNonSyncSample),61440&f.degradationPriority,15&f.degradationPriority,p>>>24&255,p>>>16&255,p>>>8&255,255&p],12+16*s)}return e.box(e.types.trun,a)}},{key:"moovMP4",value:function(t){return e.box.apply(e,[e.types.moov,e.mvhd(t[0].duration,t[0].timescale)].concat(ck(t.map(function(t){return e.trackMP4(t)}))))}},{key:"trackMP4",value:function(t){return e.box(e.types.trak,e.tkhd(t.id,t.duration,t.width,t.height),e.mdiaMP4(t))}},{key:"mdiaMP4",value:function(t){return e.box(e.types.mdia,e.mdhd(t.duration,t.timescale),e.hdlr(t.type),e.minfMP4(t))}},{key:"minfMP4",value:function(t){return e.box(e.types.minf,t.type===cA.VIDEO?e.VMHD:e.SMHD,e.DINF,e.stblMP4(t))}},{key:"stblMP4",value:function(t){var n=t.ext,r=[e.stsd(t),e.stts(n.stts),e.stsc(n.stsc),e.stsz(n.stsz),e.stco(n.stco)];return n.stss.length&&r.push(e.stss(n.stss)),n.ctts.length&&r.push(e.ctts(n.ctts)),e.box.apply(e,[e.types.stbl].concat(r))}},{key:"stts",value:function(t){var n=t.length,r=new Uint8Array(8*n),i=0;return t.forEach(function(e){var t=e.value,n=e.count;r.set([n>>24,n>>16&255,n>>8&255,255&n,t>>24,t>>16&255,t>>8&255,255&t],i),i+=8}),e.box(e.types.stts,cJ(new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n]),r))}},{key:"stsc",value:function(t){var n=t.length,r=new Uint8Array(12*n),i=0;return t.forEach(function(e){var t=e.firstChunk,n=e.samplesPerChunk,a=e.sampleDescIndex;r.set([t>>24,t>>16&255,t>>8&255,255&t,n>>24,n>>16&255,n>>8&255,255&n,a>>24,a>>16&255,a>>8&255,255&a],i),i+=12}),e.box(e.types.stsc,cJ(new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n]),r))}},{key:"stsz",value:function(t){var n=t.length,r=new Uint8Array(4*n),i=0;return t.forEach(function(e){r.set([e>>24,e>>16&255,e>>8&255,255&e],i),i+=4}),e.box(e.types.stsz,cJ(new Uint8Array([0,0,0,0,0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n]),r))}},{key:"stco",value:function(t){var n=t.length,r=new Uint8Array(4*n),i=0;return t.forEach(function(e){r.set([e>>24,e>>16&255,e>>8&255,255&e],i),i+=4}),e.box(e.types.stco,cJ(new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n]),r))}},{key:"stss",value:function(t){var n=t.length,r=new Uint8Array(4*n),i=0;return t.forEach(function(e){r.set([e>>24,e>>16&255,e>>8&255,255&e],i),i+=4}),e.box(e.types.stss,cJ(new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n]),r))}},{key:"ctts",value:function(t){var n=t.length,r=new Uint8Array(8*n),i=0;return t.forEach(function(e){var t=e.value,n=e.count;r.set([n>>24,n>>16&255,n>>8&255,255&n,t>>24,t>>16&255,t>>8&255,255&t],i),i+=8}),e.box(e.types.ctts,cJ(new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,255&n]),r))}},{key:"styp",value:function(){return e.box(e.types.styp,new Uint8Array([109,115,100,104,0,0,0,0,109,115,100,104,109,115,105,120]))}},{key:"sidx",value:function(t){var n=t.timescale,r=t.samples[0].duration,i=r*t.samples.length,a=t.samples[0].sampleOffset*r,s=8;t.samples.forEach(function(e){s+=e.size});var l=0;if(t.isVideo){var u,c=0;t.videoSenc&&(u=t.videoSenc),t.isVideo&&u.forEach(function(e){c+=8,e.subsamples&&e.subsamples.length&&(c+=2+6*e.subsamples.length)}),t.videoSencLength=c,l=s+141+16*t.samples.length+c,t.useEME&&t.isAudioEncryption&&!t.isVideoEncryption&&(l=s+16*t.samples.length+84)}else l=s+116+12*t.samples.length,t.useEME&&t.isAudioEncryption&&(l=s+169+12*t.samples.length+8*t.audioSenc.length);var d=new Uint8Array([0,0,0,0,0,0,0,255&t.id,n>>24&255,n>>16&255,n>>8&255,255&n,a>>24&255,a>>16&255,a>>8&255,255&a,0,0,0,0,0,0,0,1,0,l>>16&255,l>>8&255,255&l,i>>24&255,i>>16&255,i>>8&255,255&i,144,0,0,0]);return e.box(e.types.sidx,d)}},{key:"mdat",value:function(t){return e.box(e.types.mdat,t)}}]),e}();cy(c8,"types",["Opus","dOps","av01","av1C","avc1","avcC","hvc1","hvcC","dinf","dref","esds","ftyp","hdlr","mdat","mdhd","mdia","mfhd","minf","moof","moov","mp4a","mvex","mvhd","pasp","stbl","stco","stsc","stsd","stsz","stts","tfdt","tfhd","traf","trak","trex","tkhd","vmhd","smhd","ctts","stss","styp","pssh","sidx","sbgp","saiz","saio","senc","trun","encv","enca","sinf","btrt","frma","tenc","schm","schi","mehd","fiel","sdtp"].reduce(function(e,t){return e[t]=[t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2),t.charCodeAt(3)],e},Object.create(null))),cy(c8,"HDLR_TYPES",{video:new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),audio:new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0])}),cy(c8,"FTYPAVC1",c8.box(c8.types.ftyp,new Uint8Array([105,115,111,109,0,0,0,1,105,115,111,109,97,118,99,49]))),cy(c8,"FTYPHEV1",c8.box(c8.types.ftyp,new Uint8Array([105,115,111,109,0,0,0,1,105,115,111,109,104,101,118,49]))),cy(c8,"DINF",c8.box(c8.types.dinf,c8.box(c8.types.dref,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1])))),cy(c8,"VMHD",c8.box(c8.types.vmhd,new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]))),cy(c8,"SMHD",c8.box(c8.types.smhd,new Uint8Array([0,0,0,0,0,0,0,0]))),cy(c8,"StblTable",new Uint8Array([0,0,0,0,0,0,0,0])),cy(c8,"STTS",c8.box(c8.types.stts,c8.StblTable)),cy(c8,"STSC",c8.box(c8.types.stsc,c8.StblTable)),cy(c8,"STSZ",c8.box(c8.types.stsz,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]))),cy(c8,"STCO",c8.box(c8.types.stco,c8.StblTable));var c9=function(){function e(t,n){cv(this,e),this.name=t||"",this._prefix="[".concat(this.name,"]"),e.disabled=n}return cg(e,[{key:"debug",value:function(){var t;if(!e.disabled){for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];(t=console).debug.apply(t,[this._prefix].concat(r))}}},{key:"log",value:function(){var t;if(!e.disabled){for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];(t=console).log.apply(t,[this._prefix].concat(r))}}},{key:"warn",value:function(){var t;if(!e.disabled){for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];(t=console).warn.apply(t,[this._prefix].concat(r))}}},{key:"error",value:function(){var t;if(!e.disabled){for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];(t=console).error.apply(t,[this._prefix].concat(r))}}},{key:"table",value:function(){var t;e.disabled||(console.group(this._prefix),(t=console).table.apply(t,arguments),console.groupEnd())}}],[{key:"enable",value:function(){e.disabled=!1}},{key:"disable",value:function(){e.disabled=!0}}]),e}();cy(c9,"disabled",!0);var c7=function(){function e(t,n,r){cv(this,e),this.videoTrack=t,this.audioTrack=n;var i=/Chrome\/([^.]+)/.exec(navigator.userAgent);this.forceFirstIDR=i&&50>Number(i[1]),this.log=new c9("FMP4Remuxer",!r||!r.openLog||!r.openLog)}return cg(e,[{key:"remux",value:function(){var e,t,n,r,i,a=arguments.length>0&&void 0!==arguments[0]&&arguments[0],s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=this.videoTrack,u=this.audioTrack,c=l.exist(),d=u.exist(),f=[];return a&&(s&&s.initMerge?(c&&f.push(this.videoTrack),d&&f.push(this.audioTrack),n=c8.initSegment(f)):(c&&(e=c8.initSegment([this.videoTrack])),d&&(t=c8.initSegment([this.audioTrack])))),c&&l.hasSample()&&(r=this._remuxVideo()),d&&u.hasSample()&&(i=this._remuxAudio()),l.samples=[],u.samples=[],{initSegment:n,videoInitSegment:e,audioInitSegment:t,videoSegment:r,audioSegment:i}}},{key:"_remuxVideo",value:function(){var e=this.videoTrack;this.forceFirstIDR&&(e.samples[0].flag={dependsOn:2,isNonSyncSample:0});var t=e.samples,n=/av01/.test(e.codec),r=0;n?t.forEach(function(e){r+=e.data.byteLength}):t.forEach(function(e){r+=e.units.reduce(function(e,t){return e+t.byteLength},0),r+=4*e.units.length});var i=new Uint8Array(r);if(n)for(var a,s=0,l=t.length,u=0;s<l;s++)a=t[s],i.set(a.data,u),a.size=a.data.byteLength,u+=a.size;else for(var c,d=new DataView(i.buffer),f=function(e,n){n=t[h];var r=0;n.units.forEach(function(t){d.setUint32(e,t.byteLength),e+=4,i.set(t,e),e+=t.byteLength,r+=4+t.byteLength}),n.size=r,m=e,c=n},h=0,p=t.length,m=0;h<p;h++)f(m,c);var g=c8.mdat(i);return cJ(c8.moof([e]),g)}},{key:"_remuxAudio",value:function(){var e=this.audioTrack,t=new Uint8Array(e.samples.reduce(function(e,t){return e+t.size},0));e.samples.reduce(function(e,n){return t.set(n.data,e),e+n.size},0);var n=c8.mdat(t);return cJ(c8.moof([e]),n)}},{key:"reset",value:function(){this.videoTrack.reset(),this.audioTrack.reset()}}]),e}(),de=function(){function e(){uf(this,e),uv(this,"_ttfb",0),uv(this,"_demuxStart",0),uv(this,"_demuxEnd",0),uv(this,"_demuxCost",0),uv(this,"_remuxStart",0),uv(this,"_remuxEnd",0),uv(this,"_remuxCost",0),uv(this,"_appendStart",0),uv(this,"_appendEnd",0),uv(this,"_appendCost",0)}return up(e,[{key:"set",value:function(e,t){this["_".concat(e)]=t}},{key:"start",value:function(e){this["_".concat(e,"Start")]=Date.now()}},{key:"end",value:function(e){this["_".concat(e,"End")]=Date.now(),this["_".concat(e,"Cost")]=this["_".concat(e,"Cost")]+(this["_".concat(e,"End")]-this["_".concat(e,"Start")])}},{key:"transferCost",get:function(){return{ttfbCost:this._ttfb,demuxCost:this._demuxCost,remuxCost:this._remuxCost,appendCost:this._appendCost}}}]),e}(),dt={TTFB:"ttfb",DEMUX:"demux",REMUX:"remux",APPEND:"append"},dn=new uJ("BufferService"),dr=function(){var e,t,n,r,i,a;function s(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};uf(this,s),uv(this,"flv",null),uv(this,"_demuxer",new c6),uv(this,"_remuxer",null),uv(this,"_mse",null),uv(this,"_softVideo",null),uv(this,"_sourceCreated",!1),uv(this,"_needInitSegment",!0),uv(this,"_discontinuity",!0),uv(this,"_contiguous",!1),uv(this,"_initSegmentId",""),uv(this,"_cachedBuffer",null),uv(this,"_demuxStartTime",0),uv(this,"_opts",null),this.flv=e,this._opts=n,t?this._softVideo=t:(this._remuxer=new c7(this._demuxer.videoTrack,this._demuxer.audioTrack),this._mse=new u2(null,{preferMMS:"boolean"==typeof n.preferMMS?n.preferMMS:!!n.perferMMS}),this._mse.bindMedia(e.media))}return up(s,[{key:"baseDts",get:function(){var e,t;return null==(e=this._demuxer)||null==(t=e._fixer)?void 0:t._baseDts}},{key:"blobUrl",get:function(){var e;return null==(e=this._mse)?void 0:e.url}},{key:"isFull",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u2.VIDEO;return this._mse.isFull(e)}},{key:"seamlessSwitch",value:function(){this._needInitSegment=!0,this._discontinuity=!0,this._contiguous=!0,this._initSegmentId=""}},{key:"unContiguous",value:function(e){this._contiguous=!1,this._demuxStartTime=e}},{key:"reset",value:(e=ud(uu().mark(function e(){var t,n=arguments;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t=n.length>0&&void 0!==n[0]&&n[0],!(this._mse&&!t)){e.next=6;break}return e.next=4,this._mse.unbindMedia();case 4:return e.next=6,this._mse.bindMedia(this.flv.media);case 6:this._needInitSegment=!0,this._discontinuity=!0,this._contiguous=!1,this._sourceCreated=!1,this._initSegmentId="",this.resetSeamlessSwitchStats();case 12:case"end":return e.stop()}},e,this)})),function(){return e.apply(this,arguments)})},{key:"resetSeamlessSwitchStats",value:function(){this.seamlessLoadingSwitch=null,this.seamlessLoadingSwitching=!1,this._demuxer&&(this._demuxer.seamlessLoadingSwitching=!1)}},{key:"endOfStream",value:(t=ud(uu().mark(function e(){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._mse){e.next=7;break}if(!this._sourceCreated){e.next=5;break}return e.next=4,this._mse.endOfStream();case 4:this.flv.emit(cr.BUFFEREOS);case 5:e.next=8;break;case 7:this._softVideo&&this._softVideo.endOfStream();case 8:case"end":return e.stop()}},e,this)})),function(){return t.apply(this,arguments)})},{key:"updateDuration",value:(n=ud(uu().mark(function e(t){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._mse){e.next=7;break}if(this._mse.isOpened){e.next=4;break}return e.next=4,this._mse.open();case 4:return dn.debug("update duration",t),e.next=7,this._mse.updateDuration(t);case 7:case"end":return e.stop()}},e,this)})),function(e){return n.apply(this,arguments)})},{key:"destroy",value:(r=ud(uu().mark(function e(){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._mse){e.next=3;break}return e.next=3,this._mse.unbindMedia();case 3:this._mse=null,this._softVideo=null,this._demuxer=null,this._remuxer=null;case 7:case"end":return e.stop()}},e,this)})),function(){return r.apply(this,arguments)})},{key:"appendBuffer",value:(i=ud(uu().mark(function e(t){var n,r,i,a,s,l,u,c,d,f,h,p,m,g,y,_,b,w,x=this;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!1,this._cachedBuffer&&(t=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if((t=t.filter(Boolean)).length<2)return t[0];var r=new Uint8Array(t.reduce(function(e,t){return e+t.byteLength},0)),i=0;return t.forEach(function(e){r.set(e,i),i+=e.byteLength}),r}(this._cachedBuffer,t),this._cachedBuffer=null),r=this._demuxer,!(!t||!t.length||!r)){e.next=5;break}return e.abrupt("return");case 5:e.prev=5,this.flv._transferCost.start(dt.DEMUX),r.demuxAndFix(t,this.seamlessLoadingSwitching||this._discontinuity,this._contiguous,this._demuxStartTime,this.seamlessLoadingSwitching),this.seamlessLoadingSwitching=!1,this.flv._transferCost.end(dt.DEMUX),e.next=15;break;case 12:throw e.prev=12,e.t0=e.catch(5),new uW(uV.DEMUX,uV.SUB_TYPES.FLV,e.t0);case 15:if(i=r.videoTrack,a=r.audioTrack,s=r.metadataTrack,!this.seamlessLoadingSwitch||!((l=i.samples.findIndex(function(e){return e.originDts===i.lastKeyFrameDts}))>=0)){e.next=25;break}return i.samples.splice(l),e.next=22,this.seamlessLoadingSwitch();case 22:this.seamlessLoadingSwitch=null,t=null,n=!0;case 25:if(u=i.exist(),c=a.exist(),this._opts.onlyAudio&&(u=!1,i.present=!1),this._opts.onlyVideo&&(c=!1,a.present=!1),!(!u&&i.present||!c&&a.present)){e.next=42;break}if(d=0,(f=u?i:c?a:void 0)&&f.samples.length&&(d=(f.samples[f.samples.length-1].originPts-f.samples[0].originPts)/f.timescale*1e3),!(d>this._opts.analyzeDuration)){e.next=40;break}dn.warn("analyze duration exceeded, ".concat(d,"ms"),f),i.present=u,a.present=c,this.flv.emit(cr.ANALYZE_DURATION_EXCEEDED,{duration:d}),e.next=42;break;case 40:return this._cachedBuffer=t,e.abrupt("return");case 42:if(h=i.type,p=a.type,this._fireEvents(i,a,s),n||(this._discontinuity=!1,this._contiguous=!0,this._demuxStartTime=0),m=this._mse,g=function(){var e,t;null!=(e=x.flv)&&e.emit&&(null==(t=x.flv)||t.emit(cr.APPEND_BUFFER,{}))},this.flv.emit(cr.DEMUXED_TRACK,{videoTrack:i}),(y="".concat(i.codec,"/").concat(i.width,"/").concat(i.height,"/").concat(a.codec,"/").concat(a.config))!==this._initSegmentId&&(this._needInitSegment=!0,this._initSegmentId=y,this._emitMetaParsedEvent(i,a)),!m){e.next=83;break}if(this._sourceCreated){e.next=59;break}return e.next=55,m.open();case 55:u&&(dn.log("codec: video/mp4;codecs=".concat(i.codec)),m.createSource(h,"video/mp4;codecs=".concat(i.codec))),c&&(dn.log("codec: audio/mp4;codecs=".concat(a.codec)),m.createSource(p,"audio/mp4;codecs=".concat(a.codec))),this._sourceCreated=!0,this.flv.emit(cr.SOURCEBUFFER_CREATED);case 59:e.prev=59,this._needInitSegment&&!this._opts.mseLowLatency&&(i.duration=this._opts.durationForMSELowLatencyOff*i.timescale,a.duration=this._opts.durationForMSELowLatencyOff*c.timescale),this.flv._transferCost.start(dt.REMUX),_=this._remuxer.remux(this._needInitSegment),this.flv._transferCost.end(dt.REMUX),e.next=69;break;case 66:throw e.prev=66,e.t1=e.catch(59),new uW(uV.REMUX,uV.SUB_TYPES.FMP4,e.t1);case 69:if(!(this._needInitSegment&&!_.videoInitSegment&&!_.audioInitSegment)){e.next=71;break}return e.abrupt("return");case 71:return this._needInitSegment=!1,b=[],_.videoInitSegment&&b.push(m.append(h,_.videoInitSegment)),_.audioInitSegment&&b.push(m.append(p,_.audioInitSegment)),_.videoSegment&&b.push(m.append(h,_.videoSegment)),_.audioSegment&&b.push(m.append(p,_.audioSegment)),this.flv._transferCost.start(dt.APPEND),(w=Promise.all(b)).then(g).then(function(){x.flv._transferCost.end(dt.APPEND),g()}),e.abrupt("return",w);case 83:this._softVideo&&(this._softVideo.appendBuffer(i,a),g());case 84:case"end":return e.stop()}},e,this,[[5,12],[59,66]])})),function(e){return i.apply(this,arguments)})},{key:"evictBuffer",value:(a=ud(uu().mark(function e(t){var n,r,i=this;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=this.flv.media,!(!this._mse||!this._demuxer||!n||!t||t<0)){e.next=3;break}return e.abrupt("return");case 3:if(!((r=n.currentTime-t)<=0)){e.next=7;break}return e.abrupt("return");case 7:if(!(uz.start(uz.get(n))+1>=r)){e.next=10;break}return e.abrupt("return");case 10:return e.abrupt("return",this._mse.clearBuffer(0,r).then(function(){return i.flv.emit(cr.REMOVE_BUFFER,{removeEnd:r})}));case 11:case"end":return e.stop()}},e,this)})),function(e){return a.apply(this,arguments)})},{key:"_emitMetaParsedEvent",value:function(e,t){e.exist()&&this.flv.emit(cr.METADATA_PARSED,{type:"video",track:e,meta:{codec:e.codec,timescale:e.timescale,width:e.width,height:e.height,sarRatio:e.sarRatio,baseDts:e.baseDts}}),t.exist()&&this.flv.emit(cr.METADATA_PARSED,{type:"audio",track:t,meta:{codec:t.codec,channelCount:t.channelCount,sampleRate:t.sampleRate,timescale:t.timescale,baseDts:t.baseDts}}),dn.debug("track parsed",e,t)}},{key:"_fireEvents",value:function(e,t,n){var r=this;dn.debug("videoTrack samples count: ".concat(e.samples.length,", audioTrack samples count: ").concat(t.samples.length)),n.flvScriptSamples.forEach(function(e){r.flv.emit(cr.FLV_SCRIPT_DATA,e),dn.debug("flvScriptData",e)}),e.samples.forEach(function(e){e.keyframe&&r.flv.emit(cr.KEYFRAME,{pts:e.originPts})}),e.warnings.forEach(function(e){var t;switch(e.type){case cI.LARGE_AV_SHIFT:t=cr.LARGE_AV_FIRST_FRAME_GAP_DETECT;break;case cI.LARGE_VIDEO_GAP:t=cr.LARGE_VIDEO_DTS_GAP_DETECT;break;case cI.LARGE_VIDEO_GAP_BETWEEN_CHUNK:t=cr.MAX_DTS_DELTA_WITH_NEXT_SEGMENT_DETECT}t&&r.flv.emit(cr.STREAM_EXCEPTION,ul(ul({},e),{},{type:t})),dn.warn("video exception",e)}),t.warnings.forEach(function(e){var t;switch(e.type){case cI.LARGE_AUDIO_GAP:t=cr.LARGE_AUDIO_DTS_GAP_DETECT;break;case cI.AUDIO_FILLED:t=cr.AUDIO_GAP_DETECT;break;case cI.AUDIO_DROPPED:t=cr.AUDIO_OVERLAP_DETECT}t&&r.flv.emit(cr.STREAM_EXCEPTION,ul(ul({},e),{},{type:t})),dn.warn("audio exception",e)}),n.seiSamples.forEach(function(e){r.flv.emit(cr.SEI,ul(ul({},e),{},{sei:{code:e.data.type,content:e.data.payload,dts:e.pts}}))})}}]),s}();function di(e,t){var n=0,r=e.length-1,i=0,a=0,s=r;for(t<e[0]&&(n=0,a=s+1);a<=s;){if((i=a+Math.floor((s-a)/2))===r||t>=e[i]&&t<e[i+1]){n=i;break}e[i]<t?a=i+1:s=i-1}return n}var da=new uJ("flv"),ds=function(e){if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");d.prototype=Object.create(e&&e.prototype,{constructor:{value:d,writable:!0,configurable:!0}}),Object.defineProperty(d,"prototype",{writable:!1}),e&&ug(d,e);var t,n,r,i,a,s,l,u,c=(t=function(){if("undefined"==typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}(),function(){var e,n=um(d);e=t?Reflect.construct(n,arguments,um(this).constructor):n.apply(this,arguments);if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw TypeError("Derived constructors may only return object or undefined");return uy(this)});function d(e){var t,n,r;return uf(this,d),uv(uy(t=c.call(this)),"media",null),uv(uy(t),"_loading",!1),uv(uy(t),"_opts",null),uv(uy(t),"_bufferService",null),uv(uy(t),"_gapService",null),uv(uy(t),"_stats",null),uv(uy(t),"_mediaLoader",null),uv(uy(t),"_maxChunkWaitTimer",null),uv(uy(t),"_tickTimer",null),uv(uy(t),"_tickInterval",500),uv(uy(t),"_urlSwitching",!1),uv(uy(t),"_seamlessSwitching",!1),uv(uy(t),"_disconnectRetryCount",0),uv(uy(t),"_preLoadEndPoint",0),uv(uy(t),"_keyframes",null),uv(uy(t),"_acceptRanges",!0),uv(uy(t),"_onProgress",(n=ud(uu().mark(function e(n,r,i,a){var s,l,u,c,d,f,h,p,m,g;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(s=i.startTime,l=i.endTime,u=i.st,c=i.firstByteTime,t._loading=!r,t._firstProgressEmit){e.next=13;break}if(t.media){e.next=6;break}return null==(d=t._mediaLoader)||d.cancel(),e.abrupt("return");case 6:f=a.headers,h=u?c-u:l-s,t.emit(cr.TTFB,{url:t._opts.url,responseUrl:a.url,elapsed:h}),t.emit(cr.LOAD_RESPONSE_HEADERS,{headers:f}),t._transferCost.set(dt.TTFB,h),t._acceptRanges=!!(null!=f&&f.get("Accept-Ranges"))||!!(null!=f&&f.get("Content-Range")),t._firstProgressEmit=!0;case 13:if(t._bufferService){e.next=15;break}return e.abrupt("return");case 15:return clearTimeout(t._maxChunkWaitTimer),t._bandwidthService.addChunkRecord(null==n?void 0:n.byteLength,l-s),e.prev=17,e.next=20,t._bufferService.appendBuffer(n);case 20:null==(p=t._bufferService)||p.evictBuffer(t._opts.bufferBehind),e.next=33;break;case 23:if(e.prev=23,e.t0=e.catch(17),!(!t.isLive&&t._bufferService.isFull())){e.next=32;break}return e.next=28,t._mediaLoader.cancel();case 28:return t._loading=!1,m=t.bufferInfo().remaining,t._opts.preloadTime=parseInt(m)/2,e.abrupt("return");case 32:return e.abrupt("return",t._emitError(uW.create(e.t0)));case 33:if(t._urlSwitching&&(t._urlSwitching=!1,t.emit(cr.SWITCH_URL_SUCCESS,{url:t._opts.url})),t._seamlessSwitching&&(t._seamlessSwitching=!1,t._tick()),!(r&&!t.media.seeking)){e.next=40;break}return t.emit(cr.LOAD_COMPLETE),da.debug("load done"),t.isLive&&t._disconnectRetryCount<=0&&t._end(),e.abrupt("return");case 40:if(t.isLive){e.next=42;break}return e.abrupt("return");case 42:(g=t._opts.maxReaderInterval)&&t._firstProgressEmit&&(clearTimeout(t._maxChunkWaitTimer),t._maxChunkWaitTimer=setTimeout(function(){if(t._disconnectRetryCount){t._disconnectRetryCount--,t.load();return}da.debug("onMaxChunkWait",g),t._end()},g));case 44:case"end":return e.stop()}},e,null,[[17,23]])})),function(e,t,r,i){return n.apply(this,arguments)})),uv(uy(t),"_onRetryError",function(e,n){da.debug("load retry",e,n),t.emit(cr.LOAD_RETRY,{error:uW.network(e),retryTime:n})}),uv(uy(t),"_end",function(){t._clear(),t._bufferService&&t._bufferService.endOfStream(),da.debug("end stream")}),uv(uy(t),"_resetDisconnectCount",function(){t._disconnectRetryCount=t._opts.disconnectRetryCount}),uv(uy(t),"_tick",function(){clearTimeout(t._tickTimer);var e=uy(t).media;if(e){t._tickTimer=setTimeout(t._tick,t._tickInterval);var n=uz.end(uz.get(e));if(!(n<.1)&&e.readyState){var r=t._opts;if(e&&!e.paused&&!e.ended&&0!==e.playbackRate&&0!==e.readyState&&e.currentTime)t._gapService&&t._gapService.do(e,r.maxJumpDistance,t.isLive,3);else{if(!e.currentTime&&t._gapService&&r.enableStartGapJump){(t._opts.mseLowLatency||!1===t._opts.mseLowLatency&&t.bufferInfo(.3).nextStart)&&t._gapService.do(e,r.maxJumpDistance,t.isLive,3);return}r.isLive&&4===e.readyState&&n-e.currentTime>r.disconnectTime&&t.disconnect()}}}}),uv(uy(t),"_onPlay",function(){var e,n,r=t._opts.softDecode||(null==(e=t.media)||null==(n=e.buffered)?void 0:n.length);if(t.isLive){!t._loading&&r&&t.replay(void 0,!0);return}var i=t.bufferInfo();(i.start||i.nextStart)>.1&&t._tick()}),uv(uy(t),"_onLoadeddata",function(){t.isLive&&!t._opts.mseLowLatency&&t.media.duration!==1/0&&t._bufferService.updateDuration(1/0).catch(function(e){})}),uv(uy(t),"_onSeeking",ud(uu().mark(function e(){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:!t.isLive&&t.seekable&&(t._preLoadEndPoint=-1,t._checkPreload());case 1:case"end":return e.stop()}},e)}))),uv(uy(t),"_onTimeupdate",function(){if(t.media){var e=t._opts,n=t.media.currentTime;if(e.isLive&&e.maxLatency&&e.targetLatency){var r=uz.end(uz.get(t.media));r-n>=e.maxLatency&&(t.media.currentTime=r-e.targetLatency,t.emit(cr.CHASEFRAME,{currentTime:t.media.currentTime,latency:e.targetLatency}))}t._seiService.throw(n,!0),e.isLive||!t.seekable||t._loading||t._checkPreload()}}),uv(uy(t),"_onWaiting",function(){t.isLive&&!t._loading&&t._disconnectRetryCount&&(t._disconnectRetryCount--,t.load())}),uv(uy(t),"_onBufferUpdate",function(){if(!t._opts.isLive){var e=t.bufferInfo(),n=e.end,r=e.nextEnd;1>Math.abs((n||r)-t.media.duration)&&(t._end(),t.media.readyState<=2&&t._tick())}}),uv(uy(t),"_checkPreload",ud(uu().mark(function e(){var n,r,i,a,s,l,u,c,d;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(r=void 0===(n=t.bufferInfo().remaining)?0:n,i=t._opts,a=t._keyframes.filepositions,s=t._keyframes.times,l=t.media.currentTime,!(r<i.preloadTime)){e.next=19;break}if(u=di(t._keyframes.times,l+r+.1),(c=di(t._keyframes.times,l+r+t._opts.preloadTime))===u&&(c=u+1),t._preLoadEndPoint!==c){e.next=11;break}return e.abrupt("return");case 11:if(null!=(d=a[u])){e.next=14;break}return e.abrupt("return");case 14:return e.next=16,t._mediaLoader.cancel();case 16:t._loadData(null,[d,a[c]]),t._preLoadEndPoint=c,t._bufferService.unContiguous(s[u]);case 19:case"end":return e.stop()}},e)}))),uv(uy(t),"_onFlvScriptData",function(e){var n,r,i,a,s=null==(n=e.data)||null==(r=n.onMetaData)?void 0:r.keyframes,l=null==(i=e.data)||null==(a=i.onMetaData)?void 0:a.duration;s&&(t._keyframes=s),!t._opts.isLive&&l&&t._bufferService.updateDuration(l)}),(r=ul({retryCount:3,retryDelay:1e3,disconnectRetryCount:0,loadTimeout:1e4,maxReaderInterval:5e3,preloadTime:5,defaultVodLoadSize:1e7,isLive:!1,softDecode:!1,bufferBehind:10,maxJumpDistance:3,analyzeDuration:2e4,seamlesslyReload:!1,keepStatusAfterSwitch:!0,onlyVideo:!1,onlyAudio:!1,preferMMS:!1,mseLowLatency:!0,durationForMSELowLatencyOff:6,chunkCountForSpeed:50,skipChunkSize:1e3,longtimeNoReceived:3e3,enableStartGapJump:!0},e)).isLive&&r.preloadTime&&(r.maxLatency||(r.maxLatency=2*r.preloadTime),r.targetLatency||(r.targetLatency=r.preloadTime),(null===r.disconnectTime||void 0===r.disconnectTime)&&(r.disconnectTime=r.maxLatency)),t._opts=r,t.media=t._opts.media||document.createElement("video"),t._opts.media=null,t._firstProgressEmit=!1,t._mediaLoader=new cl(ul(ul({},t._opts.fetchOptions),{},{retry:t._opts.retryCount,retryDelay:t._opts.retryDelay,timeout:t._opts.loadTimeout,onRetryError:t._onRetryError,onProgress:t._onProgress,responseType:"arraybuffer"})),t._disconnectRetryCount=t._opts.disconnectRetryCount,t._transferCost=new de,t._bufferService=new dr(uy(t),t._opts.softDecode?t.media:void 0,t._opts),t._seiService=new cc(uy(t)),t._bandwidthService=new cd({chunkCountForSpeed:t._opts.chunkCountForSpeed,skipChunkSize:t._opts.skipChunkSize,longtimeNoReceived:t._opts.longtimeNoReceived}),t._stats=new ch(uy(t)),t._opts.softDecode||(t._gapService=new cu),t.media.addEventListener("play",t._onPlay),t.media.addEventListener("loadeddata",t._onLoadeddata),t.media.addEventListener("seeking",t._onSeeking),t.media.addEventListener("timeupdate",t._onTimeupdate),t.media.addEventListener("progress",t._onBufferUpdate),t.media.addEventListener("waiting",t._onWaiting),t.on(cr.FLV_SCRIPT_DATA,t._onFlvScriptData),t}return up(d,[{key:"version",get:function(){return"3.0.21"}},{key:"isLive",get:function(){return this._opts.isLive}},{key:"baseDts",get:function(){var e;return null==(e=this._bufferService)?void 0:e.baseDts}},{key:"seekable",get:function(){return!!this._keyframes&&this._acceptRanges}},{key:"loader",get:function(){return this._mediaLoader}},{key:"blobUrl",get:function(){var e;return null==(e=this._bufferService)?void 0:e.blobUrl}},{key:"speedInfo",value:function(){return{speed:this._bandwidthService.getLatestSpeed(),avgSpeed:this._bandwidthService.getAvgSpeed(),totalSize:this._bandwidthService.getTotalSize(),totalCost:this._bandwidthService.getTotalCost()}}},{key:"getStats",value:function(){return this._stats.getStats()}},{key:"bufferInfo",value:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.1;return uz.info(uz.get(this.media),null==(e=this.media)?void 0:e.currentTime,t)}},{key:"playbackQuality",value:function(){var e=this.media;if(!e)return{};if("function"==typeof e.getVideoPlaybackQuality){var t=e.getVideoPlaybackQuality();return{droppedVideoFrames:t.droppedVideoFrames||t.corruptedVideoFrames,totalVideoFrames:t.totalVideoFrames,creationTime:t.creationTime}}return{droppedVideoFrames:e.webkitDroppedFrameCount,totalVideoFrames:e.webkitDecodedFrameCount,creationTime:performance.now()}}},{key:"load",value:(n=ud(uu().mark(function e(t){var n,r=arguments;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=r.length>1&&void 0!==r[1]&&r[1],this._bufferService){e.next=3;break}return e.abrupt("return");case 3:return e.next=5,this._reset(n);case 5:this._loadData(t,this._opts.isLive?[]:[0,this._opts.defaultVodLoadSize]),clearTimeout(this._tickTimer),this._tickTimer=setTimeout(this._tick,this._tickInterval);case 8:case"end":return e.stop()}},e,this)})),function(e){return n.apply(this,arguments)})},{key:"replay",value:(r=ud(uu().mark(function e(){var t,n,r=this,i=arguments;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t=i.length>0&&void 0!==i[0]?i[0]:this._opts.seamlesslyReload,n=i.length>1?i[1]:void 0,this.media){e.next=4;break}return e.abrupt("return");case 4:if(this._resetDisconnectCount(),!t){e.next=11;break}return e.next=8,this._clear();case 8:setTimeout(function(){r._seamlessSwitching=!0,r._loadData(r._opts.url),r._bufferService.seamlessSwitch()}),e.next=13;break;case 11:return e.next=13,this.load();case 13:return e.abrupt("return",this.media.play(!n).catch(function(){}));case 14:case"end":return e.stop()}},e,this)})),function(){return r.apply(this,arguments)})},{key:"disconnect",value:function(){var e;return da.debug("disconnect!"),null==(e=this._bufferService)||e.resetSeamlessSwitchStats(),this._clear()}},{key:"switchURL",value:(i=ud(uu().mark(function e(t,n){var r=this;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this._bufferService){e.next=2;break}return e.abrupt("return");case 2:if(this._resetDisconnectCount(),!(this._loading&&n)){e.next=6;break}return this._bufferService.seamlessLoadingSwitch=function(){var e=ud(uu().mark(function e(n){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,r._clear();case 2:r._bufferService.seamlessLoadingSwitching=!0,r._urlSwitching=!0,r._seamlessSwitching=!0,r._bufferService.seamlessSwitch(),r._loadData(t);case 7:case"end":return e.stop()}},e)}));return function(t){return e.apply(this,arguments)}}(),e.abrupt("return");case 6:if(!(!n||!this._opts.isLive)){e.next=11;break}return e.next=9,this.load(t);case 9:return this._urlSwitching=!0,e.abrupt("return",this.media.play(!0).catch(function(){}));case 11:return e.next=13,this._clear();case 13:setTimeout(function(){r._urlSwitching=!0,r._seamlessSwitching=!0,r._loadData(t),r._bufferService.seamlessSwitch()});case 14:case"end":return e.stop()}},e,this)})),function(e,t){return i.apply(this,arguments)})},{key:"destroy",value:(a=ud(uu().mark(function e(){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.media){e.next=2;break}return e.abrupt("return");case 2:return this.removeAllListeners(),this._seiService.reset(),this.media.removeEventListener("play",this._onPlay),this.media.removeEventListener("loadeddata",this._onLoadeddata),this.media.removeEventListener("seeking",this._onSeeking),this.media.removeEventListener("timeupdate",this._onTimeupdate),this.media.removeEventListener("waiting",this._onWaiting),this.media.removeEventListener("progress",this._onBufferUpdate),e.next=12,Promise.all([this._clear(),this._bufferService.destroy()]);case 12:this.media=null,this._bufferService=null;case 14:case"end":return e.stop()}},e,this)})),function(){return a.apply(this,arguments)})},{key:"_emitError",value:function(e){var t,n=!(arguments.length>1)||void 0===arguments[1]||arguments[1];da.table(e),da.error(e),da.error(null==(t=this.media)?void 0:t.error),this._urlSwitching&&(this._urlSwitching=!1,this._seamlessSwitching=!1,this.emit(cr.SWITCH_URL_FAILED,e)),this.emit(cr.ERROR,e),n&&(this._seiService.reset(),this._end())}},{key:"_reset",value:(s=ud(uu().mark(function e(){var t,n=arguments;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]&&n[0],this._seiService.reset(),this._bandwidthService.reset(),this._stats.reset(),e.next=6,this._clear();case 6:return e.next=8,this._bufferService.reset(t);case 8:case"end":return e.stop()}},e,this)})),function(){return s.apply(this,arguments)})},{key:"_loadData",value:(l=ud(uu().mark(function e(t,n){var r;return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t&&(this._opts.url=t),r=t=this._opts.url,t){e.next=4;break}throw Error("Source url is missing");case 4:if(this._opts.preProcessUrl&&(r=this._opts.preProcessUrl(t).url),this._mediaLoader.finnalUrl=r,this.emit(cr.LOAD_START,{url:r,seamlessSwitching:this._seamlessSwitching}),da.debug("load data, loading:",this._loading,r),!this._loading){e.next=11;break}return e.next=11,this._mediaLoader.cancel();case 11:return this._loading=!0,e.prev=12,e.next=15,this._mediaLoader.load({url:r,range:n});case 15:e.next=21;break;case 17:return e.prev=17,e.t0=e.catch(12),this._loading=!1,e.abrupt("return",this._emitError(uW.network(e.t0),!1));case 21:case"end":return e.stop()}},e,this,[[12,17]])})),function(e,t){return l.apply(this,arguments)})},{key:"_clear",value:(u=ud(uu().mark(function e(){return uu().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._mediaLoader){e.next=3;break}return e.next=3,this._mediaLoader.cancel();case 3:clearTimeout(this._maxChunkWaitTimer),clearTimeout(this._tickTimer),this._loading=!1,this._firstProgressEmit=!1;case 7:case"end":return e.stop()}},e,this)})),function(){return u.apply(this,arguments)})}],[{key:"isSupported",value:function(e){return e&&"video"!==e&&"audio"!==e?"undefined"!=typeof WebAssembly:u2.isSupported()}},{key:"enableLogger",value:function(){uJ.enable(),cF.enable()}},{key:"disableLogger",value:function(){uJ.disable(),cF.disable()}}]),d}(cp.default);try{localStorage.getItem("xgd")?ds.enableLogger():ds.disableLogger()}catch(e){}function dl(e){let t=e.length;for(;--t>=0;)e[t]=0}let du=573,dc=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]),dd=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]),df=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),dh=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),dp=Array(576);dl(dp);let dv=Array(60);dl(dv);let dm=Array(512);dl(dm);let dg=Array(256);dl(dg);let dy=Array(29);dl(dy);let d_=Array(30);function db(e,t,n,r,i){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=e&&e.length}function dw(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}dl(d_);let dx=e=>e<256?dm[e]:dm[256+(e>>>7)],dk=(e,t)=>{e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255},dS=(e,t,n)=>{e.bi_valid>16-n?(e.bi_buf|=t<<e.bi_valid&65535,dk(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=n-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=n)},dE=(e,t,n)=>{dS(e,n[2*t],n[2*t+1])},dT=(e,t)=>{let n=0;do n|=1&e,e>>>=1,n<<=1;while(--t>0);return n>>>1},dA=e=>{16===e.bi_valid?(dk(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)},dO=(e,t)=>{let n,r,i,a,s,l,u=t.dyn_tree,c=t.max_code,d=t.stat_desc.static_tree,f=t.stat_desc.has_stree,h=t.stat_desc.extra_bits,p=t.stat_desc.extra_base,m=t.stat_desc.max_length,g=0;for(a=0;a<=15;a++)e.bl_count[a]=0;for(u[2*e.heap[e.heap_max]+1]=0,n=e.heap_max+1;n<du;n++)(a=u[2*u[2*(r=e.heap[n])+1]+1]+1)>m&&(a=m,g++),u[2*r+1]=a,!(r>c)&&(e.bl_count[a]++,s=0,r>=p&&(s=h[r-p]),l=u[2*r],e.opt_len+=l*(a+s),f&&(e.static_len+=l*(d[2*r+1]+s)));if(0!==g){do{for(a=m-1;0===e.bl_count[a];)a--;e.bl_count[a]--,e.bl_count[a+1]+=2,e.bl_count[m]--,g-=2}while(g>0);for(a=m;0!==a;a--)for(r=e.bl_count[a];0!==r;)!((i=e.heap[--n])>c)&&(u[2*i+1]!==a&&(e.opt_len+=(a-u[2*i+1])*u[2*i],u[2*i+1]=a),r--)}},dC=(e,t,n)=>{let r,i,a=Array(16),s=0;for(r=1;r<=15;r++)s=s+n[r-1]<<1,a[r]=s;for(i=0;i<=t;i++){let t=e[2*i+1];0!==t&&(e[2*i]=dT(a[t]++,t))}},dI=()=>{let e,t,n,r,i,a=Array(16);for(r=0,n=0;r<28;r++)for(e=0,dy[r]=n;e<1<<dc[r];e++)dg[n++]=r;for(dg[n-1]=r,i=0,r=0;r<16;r++)for(e=0,d_[r]=i;e<1<<dd[r];e++)dm[i++]=r;for(i>>=7;r<30;r++)for(e=0,d_[r]=i<<7;e<1<<dd[r]-7;e++)dm[256+i++]=r;for(t=0;t<=15;t++)a[t]=0;for(e=0;e<=143;)dp[2*e+1]=8,e++,a[8]++;for(;e<=255;)dp[2*e+1]=9,e++,a[9]++;for(;e<=279;)dp[2*e+1]=7,e++,a[7]++;for(;e<=287;)dp[2*e+1]=8,e++,a[8]++;for(dC(dp,287,a),e=0;e<30;e++)dv[2*e+1]=5,dv[2*e]=dT(e,5);g=new db(dp,dc,257,286,15),y=new db(dv,dd,0,30,15),_=new db([],df,0,19,7)},dD=e=>{let t;for(t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},dR=e=>{e.bi_valid>8?dk(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},dU=(e,t,n,r)=>{let i=2*t,a=2*n;return e[i]<e[a]||e[i]===e[a]&&r[t]<=r[n]},dL=(e,t,n)=>{let r=e.heap[n],i=n<<1;for(;i<=e.heap_len&&(i<e.heap_len&&dU(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!dU(t,r,e.heap[i],e.depth));)e.heap[n]=e.heap[i],n=i,i<<=1;e.heap[n]=r},dP=(e,t,n)=>{let r,i,a,s,l=0;if(0!==e.sym_next)do r=(255&e.pending_buf[e.sym_buf+l++])+((255&e.pending_buf[e.sym_buf+l++])<<8),i=e.pending_buf[e.sym_buf+l++],0===r?dE(e,i,t):(dE(e,(a=dg[i])+256+1,t),0!==(s=dc[a])&&dS(e,i-=dy[a],s),dE(e,a=dx(--r),n),0!==(s=dd[a])&&dS(e,r-=d_[a],s));while(l<e.sym_next);dE(e,256,t)},dB=(e,t)=>{let n,r,i,a=t.dyn_tree,s=t.stat_desc.static_tree,l=t.stat_desc.has_stree,u=t.stat_desc.elems,c=-1;for(n=0,e.heap_len=0,e.heap_max=du;n<u;n++)0!==a[2*n]?(e.heap[++e.heap_len]=c=n,e.depth[n]=0):a[2*n+1]=0;for(;e.heap_len<2;)a[2*(i=e.heap[++e.heap_len]=c<2?++c:0)]=1,e.depth[i]=0,e.opt_len--,l&&(e.static_len-=s[2*i+1]);for(t.max_code=c,n=e.heap_len>>1;n>=1;n--)dL(e,a,n);i=u;do n=e.heap[1],e.heap[1]=e.heap[e.heap_len--],dL(e,a,1),r=e.heap[1],e.heap[--e.heap_max]=n,e.heap[--e.heap_max]=r,a[2*i]=a[2*n]+a[2*r],e.depth[i]=(e.depth[n]>=e.depth[r]?e.depth[n]:e.depth[r])+1,a[2*n+1]=a[2*r+1]=i,e.heap[1]=i++,dL(e,a,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],dO(e,t),dC(a,c,e.bl_count)},dM=(e,t,n)=>{let r,i,a=-1,s=t[1],l=0,u=7,c=4;for(0===s&&(u=138,c=3),t[(n+1)*2+1]=65535,r=0;r<=n;r++)i=s,s=t[(r+1)*2+1],++l<u&&i===s||(l<c?e.bl_tree[2*i]+=l:0!==i?(i!==a&&e.bl_tree[2*i]++,e.bl_tree[32]++):l<=10?e.bl_tree[34]++:e.bl_tree[36]++,l=0,a=i,0===s?(u=138,c=3):i===s?(u=6,c=3):(u=7,c=4))},dN=(e,t,n)=>{let r,i,a=-1,s=t[1],l=0,u=7,c=4;for(0===s&&(u=138,c=3),r=0;r<=n;r++)if(i=s,s=t[(r+1)*2+1],!(++l<u)||i!==s){if(l<c)do dE(e,i,e.bl_tree);while(0!=--l);else 0!==i?(i!==a&&(dE(e,i,e.bl_tree),l--),dE(e,16,e.bl_tree),dS(e,l-3,2)):l<=10?(dE(e,17,e.bl_tree),dS(e,l-3,3)):(dE(e,18,e.bl_tree),dS(e,l-11,7));l=0,a=i,0===s?(u=138,c=3):i===s?(u=6,c=3):(u=7,c=4)}},dF=e=>{let t;for(dM(e,e.dyn_ltree,e.l_desc.max_code),dM(e,e.dyn_dtree,e.d_desc.max_code),dB(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*dh[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t},dj=(e,t,n,r)=>{let i;for(dS(e,t-257,5),dS(e,n-1,5),dS(e,r-4,4),i=0;i<r;i++)dS(e,e.bl_tree[2*dh[i]+1],3);dN(e,e.dyn_ltree,t-1),dN(e,e.dyn_dtree,n-1)},dz=e=>{let t,n=0xf3ffc07f;for(t=0;t<=31;t++,n>>>=1)if(1&n&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<256;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0},dG=!1,dV=(e,t,n,r)=>{dS(e,0+ +!!r,3),dR(e),dk(e,n),dk(e,~n),n&&e.pending_buf.set(e.window.subarray(t,t+n),e.pending),e.pending+=n};var dH={_tr_init:e=>{dG||(dI(),dG=!0),e.l_desc=new dw(e.dyn_ltree,g),e.d_desc=new dw(e.dyn_dtree,y),e.bl_desc=new dw(e.bl_tree,_),e.bi_buf=0,e.bi_valid=0,dD(e)},_tr_stored_block:dV,_tr_flush_block:(e,t,n,r)=>{let i,a,s=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=dz(e)),dB(e,e.l_desc),dB(e,e.d_desc),s=dF(e),i=e.opt_len+3+7>>>3,(a=e.static_len+3+7>>>3)<=i&&(i=a)):i=a=n+5,n+4<=i&&-1!==t?dV(e,t,n,r):4===e.strategy||a===i?(dS(e,2+ +!!r,3),dP(e,dp,dv)):(dS(e,4+ +!!r,3),dj(e,e.l_desc.max_code+1,e.d_desc.max_code+1,s+1),dP(e,e.dyn_ltree,e.dyn_dtree)),dD(e),r&&dR(e)},_tr_tally:(e,t,n)=>(e.pending_buf[e.sym_buf+e.sym_next++]=t,e.pending_buf[e.sym_buf+e.sym_next++]=t>>8,e.pending_buf[e.sym_buf+e.sym_next++]=n,0===t?e.dyn_ltree[2*n]++:(e.matches++,t--,e.dyn_ltree[(dg[n]+256+1)*2]++,e.dyn_dtree[2*dx(t)]++),e.sym_next===e.sym_end),_tr_align:e=>{dS(e,2,3),dE(e,256,dp),dA(e)}},dW=(e,t,n,r)=>{let i=65535&e|0,a=e>>>16&65535|0,s=0;for(;0!==n;){s=n>2e3?2e3:n,n-=s;do a=a+(i=i+t[r++]|0)|0;while(--s);i%=65521,a%=65521}return i|a<<16|0};let dq=new Uint32Array((()=>{let e,t=[];for(var n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?0xedb88320^e>>>1:e>>>1;t[n]=e}return t})());var dK=(e,t,n,r)=>{let i=r+n;e^=-1;for(let n=r;n<i;n++)e=e>>>8^dq[(e^t[n])&255];return -1^e},dJ={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"},dZ={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};let{_tr_init:d$,_tr_stored_block:dY,_tr_flush_block:dQ,_tr_tally:dX,_tr_align:d0}=dH,{Z_NO_FLUSH:d1,Z_PARTIAL_FLUSH:d2,Z_FULL_FLUSH:d5,Z_FINISH:d3,Z_BLOCK:d6,Z_OK:d4,Z_STREAM_END:d8,Z_STREAM_ERROR:d9,Z_DATA_ERROR:d7,Z_BUF_ERROR:fe,Z_DEFAULT_COMPRESSION:ft,Z_FILTERED:fn,Z_HUFFMAN_ONLY:fr,Z_RLE:fi,Z_FIXED:fa,Z_DEFAULT_STRATEGY:fs,Z_UNKNOWN:fo,Z_DEFLATED:fl}=dZ,fu=573,fc=(e,t)=>(e.msg=dJ[t],t),fd=e=>2*e-9*(e>4),ff=e=>{let t=e.length;for(;--t>=0;)e[t]=0},fh=e=>{let t,n,r,i=e.w_size;r=t=e.hash_size;do n=e.head[--r],e.head[r]=n>=i?n-i:0;while(--t);r=t=i;do n=e.prev[--r],e.prev[r]=n>=i?n-i:0;while(--t)},fp=(e,t,n)=>(t<<e.hash_shift^n)&e.hash_mask,fv=e=>{let t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(e.output.set(t.pending_buf.subarray(t.pending_out,t.pending_out+n),e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,0===t.pending&&(t.pending_out=0))},fm=(e,t)=>{dQ(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,fv(e.strm)},fg=(e,t)=>{e.pending_buf[e.pending++]=t},fy=(e,t)=>{e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t},f_=(e,t,n,r)=>{let i=e.avail_in;return(i>r&&(i=r),0===i)?0:(e.avail_in-=i,t.set(e.input.subarray(e.next_in,e.next_in+i),n),1===e.state.wrap?e.adler=dW(e.adler,t,i,n):2===e.state.wrap&&(e.adler=dK(e.adler,t,i,n)),e.next_in+=i,e.total_in+=i,i)},fb=(e,t)=>{let n,r,i=e.max_chain_length,a=e.strstart,s=e.prev_length,l=e.nice_match,u=e.strstart>e.w_size-262?e.strstart-(e.w_size-262):0,c=e.window,d=e.w_mask,f=e.prev,h=e.strstart+258,p=c[a+s-1],m=c[a+s];e.prev_length>=e.good_match&&(i>>=2),l>e.lookahead&&(l=e.lookahead);do{if(c[(n=t)+s]!==m||c[n+s-1]!==p||c[n]!==c[a]||c[++n]!==c[a+1])continue;a+=2,n++;do;while(c[++a]===c[++n]&&c[++a]===c[++n]&&c[++a]===c[++n]&&c[++a]===c[++n]&&c[++a]===c[++n]&&c[++a]===c[++n]&&c[++a]===c[++n]&&c[++a]===c[++n]&&a<h);if(r=258-(h-a),a=h-258,r>s){if(e.match_start=t,s=r,r>=l)break;p=c[a+s-1],m=c[a+s]}}while((t=f[t&d])>u&&0!=--i);return s<=e.lookahead?s:e.lookahead},fw=e=>{let t,n,r,i=e.w_size;do{if(n=e.window_size-e.lookahead-e.strstart,e.strstart>=i+(i-262)&&(e.window.set(e.window.subarray(i,i+i-n),0),e.match_start-=i,e.strstart-=i,e.block_start-=i,e.insert>e.strstart&&(e.insert=e.strstart),fh(e),n+=i),0===e.strm.avail_in)break;if(t=f_(e.strm,e.window,e.strstart+e.lookahead,n),e.lookahead+=t,e.lookahead+e.insert>=3)for(r=e.strstart-e.insert,e.ins_h=e.window[r],e.ins_h=fp(e,e.ins_h,e.window[r+1]);e.insert&&(e.ins_h=fp(e,e.ins_h,e.window[r+3-1]),e.prev[r&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=r,r++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<262&&0!==e.strm.avail_in)},fx=(e,t)=>{let n=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,r,i,a,s=0,l=e.strm.avail_in;do{if(r=65535,a=e.bi_valid+42>>3,e.strm.avail_out<a||(a=e.strm.avail_out-a,r>(i=e.strstart-e.block_start)+e.strm.avail_in&&(r=i+e.strm.avail_in),r>a&&(r=a),r<n&&(0===r&&t!==d3||t===d1||r!==i+e.strm.avail_in)))break;s=+(t===d3&&r===i+e.strm.avail_in),dY(e,0,0,s),e.pending_buf[e.pending-4]=r,e.pending_buf[e.pending-3]=r>>8,e.pending_buf[e.pending-2]=~r,e.pending_buf[e.pending-1]=~r>>8,fv(e.strm),i&&(i>r&&(i=r),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,r-=i),r&&(f_(e.strm,e.strm.output,e.strm.next_out,r),e.strm.next_out+=r,e.strm.avail_out-=r,e.strm.total_out+=r)}while(0===s);return((l-=e.strm.avail_in)&&(l>=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<=l&&(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-l,e.strm.next_in),e.strstart),e.strstart+=l,e.insert+=l>e.w_size-e.insert?e.w_size-e.insert:l),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),s)?4:t!==d1&&t!==d3&&0===e.strm.avail_in&&e.strstart===e.block_start?2:(a=e.window_size-e.strstart,e.strm.avail_in>a&&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++,a+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),a>e.strm.avail_in&&(a=e.strm.avail_in),a&&(f_(e.strm,e.window,e.strstart,a),e.strstart+=a,e.insert+=a>e.w_size-e.insert?e.w_size-e.insert:a),e.high_water<e.strstart&&(e.high_water=e.strstart),a=e.bi_valid+42>>3,n=(a=e.pending_buf_size-a>65535?65535:e.pending_buf_size-a)>e.w_size?e.w_size:a,((i=e.strstart-e.block_start)>=n||(i||t===d3)&&t!==d1&&0===e.strm.avail_in&&i<=a)&&(r=i>a?a:i,s=+(t===d3&&0===e.strm.avail_in&&r===i),dY(e,e.block_start,r,s),e.block_start+=r,fv(e.strm)),s?3:1)},fk=(e,t)=>{let n,r;for(;;){if(e.lookahead<262){if(fw(e),e.lookahead<262&&t===d1)return 1;if(0===e.lookahead)break}if(n=0,e.lookahead>=3&&(e.ins_h=fp(e,e.ins_h,e.window[e.strstart+3-1]),n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==n&&e.strstart-n<=e.w_size-262&&(e.match_length=fb(e,n)),e.match_length>=3)if(r=dX(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do e.strstart++,e.ins_h=fp(e,e.ins_h,e.window[e.strstart+3-1]),n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=fp(e,e.ins_h,e.window[e.strstart+1]);else r=dX(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(fm(e,!1),0===e.strm.avail_out))return 1}return(e.insert=e.strstart<2?e.strstart:2,t===d3)?(fm(e,!0),0===e.strm.avail_out)?3:4:e.sym_next&&(fm(e,!1),0===e.strm.avail_out)?1:2},fS=(e,t)=>{let n,r,i;for(;;){if(e.lookahead<262){if(fw(e),e.lookahead<262&&t===d1)return 1;if(0===e.lookahead)break}if(n=0,e.lookahead>=3&&(e.ins_h=fp(e,e.ins_h,e.window[e.strstart+3-1]),n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==n&&e.prev_length<e.max_lazy_match&&e.strstart-n<=e.w_size-262&&(e.match_length=fb(e,n),e.match_length<=5&&(e.strategy===fn||3===e.match_length&&e.strstart-e.match_start>4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-3,r=dX(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=i&&(e.ins_h=fp(e,e.ins_h,e.window[e.strstart+3-1]),n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(0!=--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,r&&(fm(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((r=dX(e,0,e.window[e.strstart-1]))&&fm(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return(e.match_available&&(r=dX(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,t===d3)?(fm(e,!0),0===e.strm.avail_out)?3:4:e.sym_next&&(fm(e,!1),0===e.strm.avail_out)?1:2},fE=(e,t)=>{let n,r,i,a,s=e.window;for(;;){if(e.lookahead<=258){if(fw(e),e.lookahead<=258&&t===d1)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&(r=s[i=e.strstart-1])===s[++i]&&r===s[++i]&&r===s[++i]){a=e.strstart+258;do;while(r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&i<a);e.match_length=258-(a-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(n=dX(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=dX(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(fm(e,!1),0===e.strm.avail_out))return 1}return(e.insert=0,t===d3)?(fm(e,!0),0===e.strm.avail_out)?3:4:e.sym_next&&(fm(e,!1),0===e.strm.avail_out)?1:2},fT=(e,t)=>{let n;for(;;){if(0===e.lookahead&&(fw(e),0===e.lookahead)){if(t===d1)return 1;break}if(e.match_length=0,n=dX(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(fm(e,!1),0===e.strm.avail_out))return 1}return(e.insert=0,t===d3)?(fm(e,!0),0===e.strm.avail_out)?3:4:e.sym_next&&(fm(e,!1),0===e.strm.avail_out)?1:2};function fA(e,t,n,r,i){this.good_length=e,this.max_lazy=t,this.nice_length=n,this.max_chain=r,this.func=i}let fO=[new fA(0,0,0,0,fx),new fA(4,4,8,4,fk),new fA(4,5,16,8,fk),new fA(4,6,32,32,fk),new fA(4,4,16,16,fS),new fA(8,16,32,32,fS),new fA(8,16,128,128,fS),new fA(8,32,128,256,fS),new fA(32,128,258,1024,fS),new fA(32,258,258,4096,fS)],fC=e=>{e.window_size=2*e.w_size,ff(e.head),e.max_lazy_match=fO[e.level].max_lazy,e.good_match=fO[e.level].good_length,e.nice_match=fO[e.level].nice_length,e.max_chain_length=fO[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=2,e.match_available=0,e.ins_h=0};function fI(){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=fl,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(2*fu),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),ff(this.dyn_ltree),ff(this.dyn_dtree),ff(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),ff(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),ff(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}let fD=e=>{if(!e)return 1;let t=e.state;return t&&t.strm===e&&(42===t.status||57===t.status||69===t.status||73===t.status||91===t.status||103===t.status||113===t.status||666===t.status)?0:1},fR=e=>{if(fD(e))return fc(e,d9);e.total_in=e.total_out=0,e.data_type=fo;let t=e.state;return t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=2===t.wrap?57:t.wrap?42:113,e.adler=+(2!==t.wrap),t.last_flush=-2,d$(t),d4},fU=e=>{let t=fR(e);return t===d4&&fC(e.state),t};var fL={deflateInit2:(e,t,n,r,i,a)=>{if(!e)return d9;let s=1;if(t===ft&&(t=6),r<0?(s=0,r=-r):r>15&&(s=2,r-=16),i<1||i>9||n!==fl||r<8||r>15||t<0||t>9||a<0||a>fa||8===r&&1!==s)return fc(e,d9);8===r&&(r=9);let l=new fI;return e.state=l,l.strm=e,l.status=42,l.wrap=s,l.gzhead=null,l.w_bits=r,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=i+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+3-1)/3),l.window=new Uint8Array(2*l.w_size),l.head=new Uint16Array(l.hash_size),l.prev=new Uint16Array(l.w_size),l.lit_bufsize=1<<i+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new Uint8Array(l.pending_buf_size),l.sym_buf=l.lit_bufsize,l.sym_end=(l.lit_bufsize-1)*3,l.level=t,l.strategy=a,l.method=n,fU(e)},deflateSetHeader:(e,t)=>fD(e)||2!==e.state.wrap?d9:(e.state.gzhead=t,d4),deflate:(e,t)=>{if(fD(e)||t>d6||t<0)return e?fc(e,d9):d9;let n=e.state;if(!e.output||0!==e.avail_in&&!e.input||666===n.status&&t!==d3)return fc(e,0===e.avail_out?fe:d9);let r=n.last_flush;if(n.last_flush=t,0!==n.pending){if(fv(e),0===e.avail_out)return n.last_flush=-1,d4}else if(0===e.avail_in&&fd(t)<=fd(r)&&t!==d3)return fc(e,fe);if(666===n.status&&0!==e.avail_in)return fc(e,fe);if(42===n.status&&0===n.wrap&&(n.status=113),42===n.status){let t=fl+(n.w_bits-8<<4)<<8,r=-1;if(t|=(n.strategy>=fr||n.level<2?0:n.level<6?1:6===n.level?2:3)<<6,0!==n.strstart&&(t|=32),fy(n,t+=31-t%31),0!==n.strstart&&(fy(n,e.adler>>>16),fy(n,65535&e.adler)),e.adler=1,n.status=113,fv(e),0!==n.pending)return n.last_flush=-1,d4}if(57===n.status){if(e.adler=0,fg(n,31),fg(n,139),fg(n,8),n.gzhead)fg(n,+!!n.gzhead.text+2*!!n.gzhead.hcrc+4*!!n.gzhead.extra+8*!!n.gzhead.name+16*!!n.gzhead.comment),fg(n,255&n.gzhead.time),fg(n,n.gzhead.time>>8&255),fg(n,n.gzhead.time>>16&255),fg(n,n.gzhead.time>>24&255),fg(n,9===n.level?2:4*(n.strategy>=fr||n.level<2)),fg(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(fg(n,255&n.gzhead.extra.length),fg(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(e.adler=dK(e.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=69;else if(fg(n,0),fg(n,0),fg(n,0),fg(n,0),fg(n,0),fg(n,9===n.level?2:4*(n.strategy>=fr||n.level<2)),fg(n,3),n.status=113,fv(e),0!==n.pending)return n.last_flush=-1,d4}if(69===n.status){if(n.gzhead.extra){let t=n.pending,r=(65535&n.gzhead.extra.length)-n.gzindex;for(;n.pending+r>n.pending_buf_size;){let i=n.pending_buf_size-n.pending;if(n.pending_buf.set(n.gzhead.extra.subarray(n.gzindex,n.gzindex+i),n.pending),n.pending=n.pending_buf_size,n.gzhead.hcrc&&n.pending>t&&(e.adler=dK(e.adler,n.pending_buf,n.pending-t,t)),n.gzindex+=i,fv(e),0!==n.pending)return n.last_flush=-1,d4;t=0,r-=i}let i=new Uint8Array(n.gzhead.extra);n.pending_buf.set(i.subarray(n.gzindex,n.gzindex+r),n.pending),n.pending+=r,n.gzhead.hcrc&&n.pending>t&&(e.adler=dK(e.adler,n.pending_buf,n.pending-t,t)),n.gzindex=0}n.status=73}if(73===n.status){if(n.gzhead.name){let t,r=n.pending;do{if(n.pending===n.pending_buf_size){if(n.gzhead.hcrc&&n.pending>r&&(e.adler=dK(e.adler,n.pending_buf,n.pending-r,r)),fv(e),0!==n.pending)return n.last_flush=-1,d4;r=0}t=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0,fg(n,t)}while(0!==t);n.gzhead.hcrc&&n.pending>r&&(e.adler=dK(e.adler,n.pending_buf,n.pending-r,r)),n.gzindex=0}n.status=91}if(91===n.status){if(n.gzhead.comment){let t,r=n.pending;do{if(n.pending===n.pending_buf_size){if(n.gzhead.hcrc&&n.pending>r&&(e.adler=dK(e.adler,n.pending_buf,n.pending-r,r)),fv(e),0!==n.pending)return n.last_flush=-1,d4;r=0}t=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0,fg(n,t)}while(0!==t);n.gzhead.hcrc&&n.pending>r&&(e.adler=dK(e.adler,n.pending_buf,n.pending-r,r))}n.status=103}if(103===n.status){if(n.gzhead.hcrc){if(n.pending+2>n.pending_buf_size&&(fv(e),0!==n.pending))return n.last_flush=-1,d4;fg(n,255&e.adler),fg(n,e.adler>>8&255),e.adler=0}if(n.status=113,fv(e),0!==n.pending)return n.last_flush=-1,d4}if(0!==e.avail_in||0!==n.lookahead||t!==d1&&666!==n.status){let r=0===n.level?fx(n,t):n.strategy===fr?fT(n,t):n.strategy===fi?fE(n,t):fO[n.level].func(n,t);if((3===r||4===r)&&(n.status=666),1===r||3===r)return 0===e.avail_out&&(n.last_flush=-1),d4;if(2===r&&(t===d2?d0(n):t!==d6&&(dY(n,0,0,!1),t===d5&&(ff(n.head),0===n.lookahead&&(n.strstart=0,n.block_start=0,n.insert=0))),fv(e),0===e.avail_out))return n.last_flush=-1,d4}return t!==d3?d4:n.wrap<=0?d8:(2===n.wrap?(fg(n,255&e.adler),fg(n,e.adler>>8&255),fg(n,e.adler>>16&255),fg(n,e.adler>>24&255),fg(n,255&e.total_in),fg(n,e.total_in>>8&255),fg(n,e.total_in>>16&255),fg(n,e.total_in>>24&255)):(fy(n,e.adler>>>16),fy(n,65535&e.adler)),fv(e),n.wrap>0&&(n.wrap=-n.wrap),0!==n.pending?d4:d8)},deflateEnd:e=>{if(fD(e))return d9;let t=e.state.status;return e.state=null,113===t?fc(e,d7):d4},deflateSetDictionary:(e,t)=>{let n=t.length;if(fD(e))return d9;let r=e.state,i=r.wrap;if(2===i||1===i&&42!==r.status||r.lookahead)return d9;if(1===i&&(e.adler=dW(e.adler,t,n,0)),r.wrap=0,n>=r.w_size){0===i&&(ff(r.head),r.strstart=0,r.block_start=0,r.insert=0);let e=new Uint8Array(r.w_size);e.set(t.subarray(n-r.w_size,n),0),t=e,n=r.w_size}let a=e.avail_in,s=e.next_in,l=e.input;for(e.avail_in=n,e.next_in=0,e.input=t,fw(r);r.lookahead>=3;){let e=r.strstart,t=r.lookahead-2;do r.ins_h=fp(r,r.ins_h,r.window[e+3-1]),r.prev[e&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=e,e++;while(--t);r.strstart=e,r.lookahead=2,fw(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,e.next_in=s,e.input=l,e.avail_in=a,r.wrap=i,d4}};let fP=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var fB={assign:function(e){let t=Array.prototype.slice.call(arguments,1);for(;t.length;){let n=t.shift();if(n){if("object"!=typeof n)throw TypeError(n+"must be non-object");for(let t in n)fP(n,t)&&(e[t]=n[t])}}return e},flattenChunks:e=>{let t=0;for(let n=0,r=e.length;n<r;n++)t+=e[n].length;let n=new Uint8Array(t);for(let t=0,r=0,i=e.length;t<i;t++){let i=e[t];n.set(i,r),r+=i.length}return n}};let fM=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){fM=!1}let fN=new Uint8Array(256);for(let e=0;e<256;e++)fN[e]=e>=252?6:e>=248?5:e>=240?4:e>=224?3:e>=192?2:1;fN[254]=fN[254]=1;let fF=(e,t)=>{if(t<65534&&e.subarray&&fM)return String.fromCharCode.apply(null,e.length===t?e:e.subarray(0,t));let n="";for(let r=0;r<t;r++)n+=String.fromCharCode(e[r]);return n};var fj={string2buf:e=>{if("function"==typeof TextEncoder&&TextEncoder.prototype.encode)return new TextEncoder().encode(e);let t,n,r,i,a,s=e.length,l=0;for(i=0;i<s;i++)(64512&(n=e.charCodeAt(i)))==55296&&i+1<s&&(64512&(r=e.charCodeAt(i+1)))==56320&&(n=65536+(n-55296<<10)+(r-56320),i++),l+=n<128?1:n<2048?2:n<65536?3:4;for(a=0,t=new Uint8Array(l),i=0;a<l;i++)(64512&(n=e.charCodeAt(i)))==55296&&i+1<s&&(64512&(r=e.charCodeAt(i+1)))==56320&&(n=65536+(n-55296<<10)+(r-56320),i++),n<128?t[a++]=n:(n<2048?t[a++]=192|n>>>6:(n<65536?t[a++]=224|n>>>12:(t[a++]=240|n>>>18,t[a++]=128|n>>>12&63),t[a++]=128|n>>>6&63),t[a++]=128|63&n);return t},buf2string:(e,t)=>{let n,r,i=t||e.length;if("function"==typeof TextDecoder&&TextDecoder.prototype.decode)return new TextDecoder().decode(e.subarray(0,t));let a=Array(2*i);for(r=0,n=0;n<i;){let t=e[n++];if(t<128){a[r++]=t;continue}let s=fN[t];if(s>4){a[r++]=65533,n+=s-1;continue}for(t&=2===s?31:3===s?15:7;s>1&&n<i;)t=t<<6|63&e[n++],s--;if(s>1){a[r++]=65533;continue}t<65536?a[r++]=t:(t-=65536,a[r++]=55296|t>>10&1023,a[r++]=56320|1023&t)}return fF(a,r)},utf8border:(e,t)=>{(t=t||e.length)>e.length&&(t=e.length);let n=t-1;for(;n>=0&&(192&e[n])==128;)n--;return n<0||0===n?t:n+fN[e[n]]>t?n:t}},fz=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0};let fG=Object.prototype.toString,{Z_NO_FLUSH:fV,Z_SYNC_FLUSH:fH,Z_FULL_FLUSH:fW,Z_FINISH:fq,Z_OK:fK,Z_STREAM_END:fJ,Z_DEFAULT_COMPRESSION:fZ,Z_DEFAULT_STRATEGY:f$,Z_DEFLATED:fY}=dZ;function fQ(e){this.options=fB.assign({level:fZ,method:fY,chunkSize:16384,windowBits:15,memLevel:8,strategy:f$},e||{});let t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new fz,this.strm.avail_out=0;let n=fL.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(n!==fK)throw Error(dJ[n]);if(t.header&&fL.deflateSetHeader(this.strm,t.header),t.dictionary){let e;if(e="string"==typeof t.dictionary?fj.string2buf(t.dictionary):"[object ArrayBuffer]"===fG.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(n=fL.deflateSetDictionary(this.strm,e))!==fK)throw Error(dJ[n]);this._dict_set=!0}}function fX(e,t){let n=new fQ(t);if(n.push(e,!0),n.err)throw n.msg||dJ[n.err];return n.result}fQ.prototype.push=function(e,t){let n,r,i=this.strm,a=this.options.chunkSize;if(this.ended)return!1;for(r=t===~~t?t:!0===t?fq:fV,"string"==typeof e?i.input=fj.string2buf(e):"[object ArrayBuffer]"===fG.call(e)?i.input=new Uint8Array(e):i.input=e,i.next_in=0,i.avail_in=i.input.length;;){if(0===i.avail_out&&(i.output=new Uint8Array(a),i.next_out=0,i.avail_out=a),(r===fH||r===fW)&&i.avail_out<=6){this.onData(i.output.subarray(0,i.next_out)),i.avail_out=0;continue}if((n=fL.deflate(i,r))===fJ)return i.next_out>0&&this.onData(i.output.subarray(0,i.next_out)),n=fL.deflateEnd(this.strm),this.onEnd(n),this.ended=!0,n===fK;if(0===i.avail_out){this.onData(i.output);continue}if(r>0&&i.next_out>0){this.onData(i.output.subarray(0,i.next_out)),i.avail_out=0;continue}if(0===i.avail_in)break}return!0},fQ.prototype.onData=function(e){this.chunks.push(e)},fQ.prototype.onEnd=function(e){e===fK&&(this.result=fB.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var f0=function(e,t){let n,r,i,a,s,l,u,c,d,f,h,p,m,g,y,_,b,w,x,k,S,E,T,A,O=e.state;n=e.next_in,T=e.input,r=n+(e.avail_in-5),i=e.next_out,A=e.output,a=i-(t-e.avail_out),s=i+(e.avail_out-257),l=O.dmax,u=O.wsize,c=O.whave,d=O.wnext,f=O.window,h=O.hold,p=O.bits,m=O.lencode,g=O.distcode,y=(1<<O.lenbits)-1,_=(1<<O.distbits)-1;e:do for(p<15&&(h+=T[n++]<<p,p+=8,h+=T[n++]<<p,p+=8),b=m[h&y];;){if(h>>>=w=b>>>24,p-=w,0==(w=b>>>16&255))A[i++]=65535&b;else if(16&w)for(x=65535&b,(w&=15)&&(p<w&&(h+=T[n++]<<p,p+=8),x+=h&(1<<w)-1,h>>>=w,p-=w),p<15&&(h+=T[n++]<<p,p+=8,h+=T[n++]<<p,p+=8),b=g[h&_];;){if(h>>>=w=b>>>24,p-=w,16&(w=b>>>16&255)){if(k=65535&b,p<(w&=15)&&(h+=T[n++]<<p,(p+=8)<w&&(h+=T[n++]<<p,p+=8)),(k+=h&(1<<w)-1)>l){e.msg="invalid distance too far back",O.mode=16209;break e}if(h>>>=w,p-=w,k>(w=i-a)){if((w=k-w)>c&&O.sane){e.msg="invalid distance too far back",O.mode=16209;break e}if(S=0,E=f,0===d){if(S+=u-w,w<x){x-=w;do A[i++]=f[S++];while(--w);S=i-k,E=A}}else if(d<w){if(S+=u+d-w,(w-=d)<x){x-=w;do A[i++]=f[S++];while(--w);if(S=0,d<x){x-=w=d;do A[i++]=f[S++];while(--w);S=i-k,E=A}}}else if(S+=d-w,w<x){x-=w;do A[i++]=f[S++];while(--w);S=i-k,E=A}for(;x>2;)A[i++]=E[S++],A[i++]=E[S++],A[i++]=E[S++],x-=3;x&&(A[i++]=E[S++],x>1&&(A[i++]=E[S++]))}else{S=i-k;do A[i++]=A[S++],A[i++]=A[S++],A[i++]=A[S++],x-=3;while(x>2);x&&(A[i++]=A[S++],x>1&&(A[i++]=A[S++]))}}else if((64&w)==0){b=g[(65535&b)+(h&(1<<w)-1)];continue}else{e.msg="invalid distance code",O.mode=16209;break e}break}else if((64&w)==0){b=m[(65535&b)+(h&(1<<w)-1)];continue}else if(32&w){O.mode=16191;break e}else{e.msg="invalid literal/length code",O.mode=16209;break e}break}while(n<r&&i<s);n-=x=p>>3,p-=x<<3,h&=(1<<p)-1,e.next_in=n,e.next_out=i,e.avail_in=n<r?5+(r-n):5-(n-r),e.avail_out=i<s?257+(s-i):257-(i-s),O.hold=h,O.bits=p};let f1=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]),f2=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]),f5=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]),f3=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]);var f6=(e,t,n,r,i,a,s,l)=>{let u,c,d,f,h,p,m,g,y,_=l.bits,b=0,w=0,x=0,k=0,S=0,E=0,T=0,A=0,O=0,C=0,I=null,D=new Uint16Array(16),R=new Uint16Array(16),U=null;for(b=0;b<=15;b++)D[b]=0;for(w=0;w<r;w++)D[t[n+w]]++;for(k=15,S=_;k>=1&&0===D[k];k--);if(S>k&&(S=k),0===k)return i[a++]=0x1400000,i[a++]=0x1400000,l.bits=1,0;for(x=1;x<k&&0===D[x];x++);for(S<x&&(S=x),A=1,b=1;b<=15;b++)if(A<<=1,(A-=D[b])<0)return -1;if(A>0&&(0===e||1!==k))return -1;for(b=1,R[1]=0;b<15;b++)R[b+1]=R[b]+D[b];for(w=0;w<r;w++)0!==t[n+w]&&(s[R[t[n+w]]++]=w);if(0===e?(I=U=s,p=20):1===e?(I=f1,U=f2,p=257):(I=f5,U=f3,p=0),C=0,w=0,b=x,h=a,E=S,T=0,d=-1,f=(O=1<<S)-1,1===e&&O>852||2===e&&O>592)return 1;for(;;){m=b-T,s[w]+1<p?(g=0,y=s[w]):s[w]>=p?(g=U[s[w]-p],y=I[s[w]-p]):(g=96,y=0),u=1<<b-T,x=c=1<<E;do i[h+(C>>T)+(c-=u)]=m<<24|g<<16|y|0;while(0!==c);for(u=1<<b-1;C&u;)u>>=1;if(0!==u?(C&=u-1,C+=u):C=0,w++,0==--D[b]){if(b===k)break;b=t[n+s[w]]}if(b>S&&(C&f)!==d){for(0===T&&(T=S),h+=x,A=1<<(E=b-T);E+T<k&&!((A-=D[E+T])<=0);)E++,A<<=1;if(O+=1<<E,1===e&&O>852||2===e&&O>592)return 1;i[d=C&f]=S<<24|E<<16|h-a|0}}return 0!==C&&(i[h+C]=b-T<<24|4194304),l.bits=S,0};let{Z_FINISH:f4,Z_BLOCK:f8,Z_TREES:f9,Z_OK:f7,Z_STREAM_END:he,Z_NEED_DICT:ht,Z_STREAM_ERROR:hn,Z_DATA_ERROR:hr,Z_MEM_ERROR:hi,Z_BUF_ERROR:ha,Z_DEFLATED:hs}=dZ,ho=e=>(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24);function hl(){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}let hu=e=>{if(!e)return 1;let t=e.state;return+(!t||t.strm!==e||t.mode<16180||t.mode>16211)},hc=e=>{if(hu(e))return hn;let t=e.state;return e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=16180,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(852),t.distcode=t.distdyn=new Int32Array(592),t.sane=1,t.back=-1,f7},hd=e=>{if(hu(e))return hn;let t=e.state;return t.wsize=0,t.whave=0,t.wnext=0,hc(e)},hf=(e,t)=>{let n;if(hu(e))return hn;let r=e.state;return(t<0?(n=0,t=-t):(n=(t>>4)+5,t<48&&(t&=15)),t&&(t<8||t>15))?hn:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,hd(e))},hh=!0,hp=e=>{if(hh){b=new Int32Array(512),w=new Int32Array(32);let t=0;for(;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(f6(1,e.lens,0,288,b,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;f6(2,e.lens,0,32,w,0,e.work,{bits:5}),hh=!1}e.lencode=b,e.lenbits=9,e.distcode=w,e.distbits=5},hv=(e,t,n,r)=>{let i,a=e.state;return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new Uint8Array(a.wsize)),r>=a.wsize?(a.window.set(t.subarray(n-a.wsize,n),0),a.wnext=0,a.whave=a.wsize):((i=a.wsize-a.wnext)>r&&(i=r),a.window.set(t.subarray(n-r,n-r+i),a.wnext),(r-=i)?(a.window.set(t.subarray(n-r,n),0),a.wnext=r,a.whave=a.wsize):(a.wnext+=i,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=i))),0};var hm={inflateReset:hd,inflateInit2:(e,t)=>{if(!e)return hn;let n=new hl;e.state=n,n.strm=e,n.window=null,n.mode=16180;let r=hf(e,t);return r!==f7&&(e.state=null),r},inflate:(e,t)=>{let n,r,i,a,s,l,u,c,d,f,h,p,m,g,y,_,b,w,x,k,S,E,T,A,O=0,C=new Uint8Array(4),I=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(hu(e)||!e.output||!e.input&&0!==e.avail_in)return hn;16191===(n=e.state).mode&&(n.mode=16192),s=e.next_out,i=e.output,u=e.avail_out,a=e.next_in,r=e.input,l=e.avail_in,c=n.hold,d=n.bits,f=l,h=u,E=f7;t:for(;;)switch(n.mode){case 16180:if(0===n.wrap){n.mode=16192;break}for(;d<16;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(2&n.wrap&&35615===c){0===n.wbits&&(n.wbits=15),n.check=0,C[0]=255&c,C[1]=c>>>8&255,n.check=dK(n.check,C,2,0),c=0,d=0,n.mode=16181;break}if(n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&c)<<8)+(c>>8))%31){e.msg="incorrect header check",n.mode=16209;break}if((15&c)!==hs){e.msg="unknown compression method",n.mode=16209;break}if(c>>>=4,d-=4,S=(15&c)+8,0===n.wbits&&(n.wbits=S),S>15||S>n.wbits){e.msg="invalid window size",n.mode=16209;break}n.dmax=1<<n.wbits,n.flags=0,e.adler=n.check=1,n.mode=512&c?16189:16191,c=0,d=0;break;case 16181:for(;d<16;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(n.flags=c,(255&n.flags)!==hs){e.msg="unknown compression method",n.mode=16209;break}if(57344&n.flags){e.msg="unknown header flags set",n.mode=16209;break}n.head&&(n.head.text=c>>8&1),512&n.flags&&4&n.wrap&&(C[0]=255&c,C[1]=c>>>8&255,n.check=dK(n.check,C,2,0)),c=0,d=0,n.mode=16182;case 16182:for(;d<32;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}n.head&&(n.head.time=c),512&n.flags&&4&n.wrap&&(C[0]=255&c,C[1]=c>>>8&255,C[2]=c>>>16&255,C[3]=c>>>24&255,n.check=dK(n.check,C,4,0)),c=0,d=0,n.mode=16183;case 16183:for(;d<16;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}n.head&&(n.head.xflags=255&c,n.head.os=c>>8),512&n.flags&&4&n.wrap&&(C[0]=255&c,C[1]=c>>>8&255,n.check=dK(n.check,C,2,0)),c=0,d=0,n.mode=16184;case 16184:if(1024&n.flags){for(;d<16;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}n.length=c,n.head&&(n.head.extra_len=c),512&n.flags&&4&n.wrap&&(C[0]=255&c,C[1]=c>>>8&255,n.check=dK(n.check,C,2,0)),c=0,d=0}else n.head&&(n.head.extra=null);n.mode=16185;case 16185:if(1024&n.flags&&((p=n.length)>l&&(p=l),p&&(n.head&&(S=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Uint8Array(n.head.extra_len)),n.head.extra.set(r.subarray(a,a+p),S)),512&n.flags&&4&n.wrap&&(n.check=dK(n.check,r,p,a)),l-=p,a+=p,n.length-=p),n.length))break t;n.length=0,n.mode=16186;case 16186:if(2048&n.flags){if(0===l)break t;p=0;do S=r[a+p++],n.head&&S&&n.length<65536&&(n.head.name+=String.fromCharCode(S));while(S&&p<l);if(512&n.flags&&4&n.wrap&&(n.check=dK(n.check,r,p,a)),l-=p,a+=p,S)break t}else n.head&&(n.head.name=null);n.length=0,n.mode=16187;case 16187:if(4096&n.flags){if(0===l)break t;p=0;do S=r[a+p++],n.head&&S&&n.length<65536&&(n.head.comment+=String.fromCharCode(S));while(S&&p<l);if(512&n.flags&&4&n.wrap&&(n.check=dK(n.check,r,p,a)),l-=p,a+=p,S)break t}else n.head&&(n.head.comment=null);n.mode=16188;case 16188:if(512&n.flags){for(;d<16;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(4&n.wrap&&c!==(65535&n.check)){e.msg="header crc mismatch",n.mode=16209;break}c=0,d=0}n.head&&(n.head.hcrc=n.flags>>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=16191;break;case 16189:for(;d<32;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}e.adler=n.check=ho(c),c=0,d=0,n.mode=16190;case 16190:if(0===n.havedict)return e.next_out=s,e.avail_out=u,e.next_in=a,e.avail_in=l,n.hold=c,n.bits=d,ht;e.adler=n.check=1,n.mode=16191;case 16191:if(t===f8||t===f9)break t;case 16192:if(n.last){c>>>=7&d,d-=7&d,n.mode=16206;break}for(;d<3;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}switch(n.last=1&c,d-=1,3&(c>>>=1)){case 0:n.mode=16193;break;case 1:if(hp(n),n.mode=16199,t===f9){c>>>=2,d-=2;break t}break;case 2:n.mode=16196;break;case 3:e.msg="invalid block type",n.mode=16209}c>>>=2,d-=2;break;case 16193:for(c>>>=7&d,d-=7&d;d<32;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if((65535&c)!=(c>>>16^65535)){e.msg="invalid stored block lengths",n.mode=16209;break}if(n.length=65535&c,c=0,d=0,n.mode=16194,t===f9)break t;case 16194:n.mode=16195;case 16195:if(p=n.length){if(p>l&&(p=l),p>u&&(p=u),0===p)break t;i.set(r.subarray(a,a+p),s),l-=p,a+=p,u-=p,s+=p,n.length-=p;break}n.mode=16191;break;case 16196:for(;d<14;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(n.nlen=(31&c)+257,d-=5,n.ndist=(31&(c>>>=5))+1,d-=5,n.ncode=(15&(c>>>=5))+4,c>>>=4,d-=4,n.nlen>286||n.ndist>30){e.msg="too many length or distance symbols",n.mode=16209;break}n.have=0,n.mode=16197;case 16197:for(;n.have<n.ncode;){for(;d<3;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}n.lens[I[n.have++]]=7&c,c>>>=3,d-=3}for(;n.have<19;)n.lens[I[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,T={bits:n.lenbits},E=f6(0,n.lens,0,19,n.lencode,0,n.work,T),n.lenbits=T.bits,E){e.msg="invalid code lengths set",n.mode=16209;break}n.have=0,n.mode=16198;case 16198:for(;n.have<n.nlen+n.ndist;){for(;y=(O=n.lencode[c&(1<<n.lenbits)-1])>>>24,_=O>>>16&255,b=65535&O,!(y<=d);){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(b<16)c>>>=y,d-=y,n.lens[n.have++]=b;else{if(16===b){for(A=y+2;d<A;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(c>>>=y,d-=y,0===n.have){e.msg="invalid bit length repeat",n.mode=16209;break}S=n.lens[n.have-1],p=3+(3&c),c>>>=2,d-=2}else if(17===b){for(A=y+3;d<A;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}c>>>=y,d-=y,S=0,p=3+(7&c),c>>>=3,d-=3}else{for(A=y+7;d<A;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}c>>>=y,d-=y,S=0,p=11+(127&c),c>>>=7,d-=7}if(n.have+p>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=16209;break}for(;p--;)n.lens[n.have++]=S}}if(16209===n.mode)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=16209;break}if(n.lenbits=9,T={bits:n.lenbits},E=f6(1,n.lens,0,n.nlen,n.lencode,0,n.work,T),n.lenbits=T.bits,E){e.msg="invalid literal/lengths set",n.mode=16209;break}if(n.distbits=6,n.distcode=n.distdyn,T={bits:n.distbits},E=f6(2,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,T),n.distbits=T.bits,E){e.msg="invalid distances set",n.mode=16209;break}if(n.mode=16199,t===f9)break t;case 16199:n.mode=16200;case 16200:if(l>=6&&u>=258){e.next_out=s,e.avail_out=u,e.next_in=a,e.avail_in=l,n.hold=c,n.bits=d,f0(e,h),s=e.next_out,i=e.output,u=e.avail_out,a=e.next_in,r=e.input,l=e.avail_in,c=n.hold,d=n.bits,16191===n.mode&&(n.back=-1);break}for(n.back=0;y=(O=n.lencode[c&(1<<n.lenbits)-1])>>>24,_=O>>>16&255,b=65535&O,!(y<=d);){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(_&&(240&_)==0){for(w=y,x=_,k=b;y=(O=n.lencode[k+((c&(1<<w+x)-1)>>w)])>>>24,_=O>>>16&255,b=65535&O,!(w+y<=d);){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}c>>>=w,d-=w,n.back+=w}if(c>>>=y,d-=y,n.back+=y,n.length=b,0===_){n.mode=16205;break}if(32&_){n.back=-1,n.mode=16191;break}if(64&_){e.msg="invalid literal/length code",n.mode=16209;break}n.extra=15&_,n.mode=16201;case 16201:if(n.extra){for(A=n.extra;d<A;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}n.length+=c&(1<<n.extra)-1,c>>>=n.extra,d-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=16202;case 16202:for(;y=(O=n.distcode[c&(1<<n.distbits)-1])>>>24,_=O>>>16&255,b=65535&O,!(y<=d);){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if((240&_)==0){for(w=y,x=_,k=b;y=(O=n.distcode[k+((c&(1<<w+x)-1)>>w)])>>>24,_=O>>>16&255,b=65535&O,!(w+y<=d);){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}c>>>=w,d-=w,n.back+=w}if(c>>>=y,d-=y,n.back+=y,64&_){e.msg="invalid distance code",n.mode=16209;break}n.offset=b,n.extra=15&_,n.mode=16203;case 16203:if(n.extra){for(A=n.extra;d<A;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}n.offset+=c&(1<<n.extra)-1,c>>>=n.extra,d-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=16209;break}n.mode=16204;case 16204:if(0===u)break t;if(p=h-u,n.offset>p){if((p=n.offset-p)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=16209;break}p>n.wnext?(p-=n.wnext,m=n.wsize-p):m=n.wnext-p,p>n.length&&(p=n.length),g=n.window}else g=i,m=s-n.offset,p=n.length;p>u&&(p=u),u-=p,n.length-=p;do i[s++]=g[m++];while(--p);0===n.length&&(n.mode=16200);break;case 16205:if(0===u)break t;i[s++]=n.length,u--,n.mode=16200;break;case 16206:if(n.wrap){for(;d<32;){if(0===l)break t;l--,c|=r[a++]<<d,d+=8}if(h-=u,e.total_out+=h,n.total+=h,4&n.wrap&&h&&(e.adler=n.check=n.flags?dK(n.check,i,h,s-h):dW(n.check,i,h,s-h)),h=u,4&n.wrap&&(n.flags?c:ho(c))!==n.check){e.msg="incorrect data check",n.mode=16209;break}c=0,d=0}n.mode=16207;case 16207:if(n.wrap&&n.flags){for(;d<32;){if(0===l)break t;l--,c+=r[a++]<<d,d+=8}if(4&n.wrap&&c!==(0xffffffff&n.total)){e.msg="incorrect length check",n.mode=16209;break}c=0,d=0}n.mode=16208;case 16208:E=he;break t;case 16209:E=hr;break t;case 16210:return hi;default:return hn}return e.next_out=s,e.avail_out=u,e.next_in=a,e.avail_in=l,n.hold=c,n.bits=d,(n.wsize||h!==e.avail_out&&n.mode<16209&&(n.mode<16206||t!==f4))&&hv(e,e.output,e.next_out,h-e.avail_out),f-=e.avail_in,h-=e.avail_out,e.total_in+=f,e.total_out+=h,n.total+=h,4&n.wrap&&h&&(e.adler=n.check=n.flags?dK(n.check,i,h,e.next_out-h):dW(n.check,i,h,e.next_out-h)),e.data_type=n.bits+64*!!n.last+128*(16191===n.mode)+256*(16199===n.mode||16194===n.mode),(0===f&&0===h||t===f4)&&E===f7&&(E=ha),E},inflateEnd:e=>{if(hu(e))return hn;let t=e.state;return t.window&&(t.window=null),e.state=null,f7},inflateGetHeader:(e,t)=>{if(hu(e))return hn;let n=e.state;return(2&n.wrap)==0?hn:(n.head=t,t.done=!1,f7)},inflateSetDictionary:(e,t)=>{let n,r,i=t.length;return hu(e)||0!==(n=e.state).wrap&&16190!==n.mode?hn:16190===n.mode&&dW(1,t,i,0)!==n.check?hr:hv(e,t,i,i)?(n.mode=16210,hi):(n.havedict=1,f7)}},hg=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1};let hy=Object.prototype.toString,{Z_NO_FLUSH:h_,Z_FINISH:hb,Z_OK:hw,Z_STREAM_END:hx,Z_NEED_DICT:hk,Z_STREAM_ERROR:hS,Z_DATA_ERROR:hE,Z_MEM_ERROR:hT}=dZ;function hA(e){this.options=fB.assign({chunkSize:65536,windowBits:15,to:""},e||{});let t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!(e&&e.windowBits)&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(15&t.windowBits)==0&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new fz,this.strm.avail_out=0;let n=hm.inflateInit2(this.strm,t.windowBits);if(n!==hw||(this.header=new hg,hm.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=fj.string2buf(t.dictionary):"[object ArrayBuffer]"===hy.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw)&&(n=hm.inflateSetDictionary(this.strm,t.dictionary))!==hw))throw Error(dJ[n])}function hO(e,t){let n=new hA(t);if(n.push(e),n.err)throw n.msg||dJ[n.err];return n.result}hA.prototype.push=function(e,t){let n,r,i,a=this.strm,s=this.options.chunkSize,l=this.options.dictionary;if(this.ended)return!1;for(r=t===~~t?t:!0===t?hb:h_,"[object ArrayBuffer]"===hy.call(e)?a.input=new Uint8Array(e):a.input=e,a.next_in=0,a.avail_in=a.input.length;;){for(0===a.avail_out&&(a.output=new Uint8Array(s),a.next_out=0,a.avail_out=s),(n=hm.inflate(a,r))===hk&&l&&((n=hm.inflateSetDictionary(a,l))===hw?n=hm.inflate(a,r):n===hE&&(n=hk));a.avail_in>0&&n===hx&&a.state.wrap>0&&0!==e[a.next_in];)hm.inflateReset(a),n=hm.inflate(a,r);switch(n){case hS:case hE:case hk:case hT:return this.onEnd(n),this.ended=!0,!1}if(i=a.avail_out,a.next_out&&(0===a.avail_out||n===hx))if("string"===this.options.to){let e=fj.utf8border(a.output,a.next_out),t=a.next_out-e,n=fj.buf2string(a.output,e);a.next_out=t,a.avail_out=s-t,t&&a.output.set(a.output.subarray(e,e+t),0),this.onData(n)}else this.onData(a.output.length===a.next_out?a.output:a.output.subarray(0,a.next_out));if(n!==hw||0!==i){if(n===hx)return n=hm.inflateEnd(this.strm),this.onEnd(n),this.ended=!0,!0;if(0===a.avail_in)break}}return!0},hA.prototype.onData=function(e){this.chunks.push(e)},hA.prototype.onEnd=function(e){e===hw&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=fB.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};let{Deflate:hC,deflate:hI,deflateRaw:hD,gzip:hR}={Deflate:fQ,deflate:fX,deflateRaw:function(e,t){return(t=t||{}).raw=!0,fX(e,t)},gzip:function(e,t){return(t=t||{}).gzip=!0,fX(e,t)},constants:dZ},{Inflate:hU,inflate:hL,inflateRaw:hP,ungzip:hB}={Inflate:hA,inflate:hO,inflateRaw:function(e,t){return(t=t||{}).raw=!0,hO(e,t)},ungzip:hO,constants:dZ};var hM={};hM.INT8=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt8(t,n)},this._read=function(e,t,n){return e.readInt8(t,!0,n)},this._className=function(){return hM.CHAR}},hM.INT16=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt16(t,n)},this._read=function(e,t,n){return e.readInt16(t,!0,n)},this._className=function(){return hM.SHORT}},hM.INT32=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt32(t,n)},this._read=function(e,t,n){return e.readInt32(t,!0,n)},this._className=function(){return hM.INT32}},hM.INT64=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt64(t,n)},this._read=function(e,t,n){return e.readInt64(t,!0,n)},this._className=function(){return hM.INT64}},hM.UINT8=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt16(t,n)},this._read=function(e,t,n){return e.readInt16(t,!0,n)},this._className=function(){return hM.SHORT}},hM.UInt16=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt32(t,n)},this._read=function(e,t,n){return e.readInt32(t,!0,n)},this._className=function(){return hM.INT32}},hM.UInt32=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt64(t,n)},this._read=function(e,t,n){return e.readInt64(t,!0,n)},this._className=function(){return hM.INT64}},hM.Float=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeFloat(t,n)},this._read=function(e,t,n){return e.readFloat(t,!0,n)},this._className=function(){return hM.FLOAT}},hM.Double=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeDouble(t,n)},this._read=function(e,t,n){return e.readDouble(t,!0,n)},this._className=function(){return hM.DOUBLE}},hM.STRING=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeString(t,n)},this._read=function(e,t,n){return e.readString(t,!0,n)},this._className=function(){return hM.STRING}},hM.BOOLEAN=function(){this._clone=function(){return!1},this._write=function(e,t,n){return e.writeBoolean(t,n)},this._read=function(e,t,n){return e.readBoolean(t,!0,n)},this._className=function(){return hM.BOOLEAN}},hM.ENUM=function(){this._clone=function(){return 0},this._write=function(e,t,n){return e.writeInt32(t,n)},this._read=function(e,t,n){return e.readInt32(t,!0,n)}},hM.Vector=function(e){this.proto=e,this.value=[]},hM.Vector.prototype._clone=function(){return new hM.Vector(this.proto)},hM.Vector.prototype._write=function(e,t,n){return e.writeVector(t,n)},hM.Vector.prototype._read=function(e,t,n){return e.readVector(t,!0,n)},hM.Vector.prototype._className=function(){return hM.TypeHelp.VECTOR.replace("$t",this.proto._className())},hM.Map=function(e,t){this.kproto=e,this.vproto=t,this.value={}},hM.Map.prototype._clone=function(){return new hM.Map(this.kproto,this.vproto)},hM.Map.prototype._write=function(e,t,n){return e.writeMap(t,n)},hM.Map.prototype._read=function(e,t,n){return e.readMap(t,!0,n)},hM.Map.prototype.put=function(e,t){this.value[e]=t},hM.Map.prototype.get=function(e){return this.value[e]},hM.Map.prototype.remove=function(e){delete this.value[e]},hM.Map.prototype.clear=function(){this.value={}},hM.Map.prototype.size=function(){var e=0;for(var t in this.value)e++;return e},hM.Map.prototype._className=function(){return hM.TypeHelp.Map.replace("$k",this.kproto._className()).replace("$v",this.vproto._className())},hM.DataHelp={EN_INT8:0,EN_INT16:1,EN_INT32:2,EN_INT64:3,EN_FLOAT:4,EN_DOUBLE:5,EN_STRING1:6,EN_STRING4:7,EN_MAP:8,EN_LIST:9,EN_STRUCTBEGIN:10,EN_STRUCTEND:11,EN_ZERO:12,EN_SIMPLELIST:13},hM.TypeHelp={BOOLEAN:"bool",CHAR:"char",SHORT:"short",INT32:"int32",INT64:"int64",FLOAT:"float",DOUBLE:"double",STRING:"string",VECTOR:"list<$t>",MAP:"map<$k, $v>"},hM.BinBuffer=function(e){this.buf=null,this.vew=null,this.len=0,this.position=0,null!=e&&void 0!=e&&e instanceof hM.BinBuffer&&(this.buf=e.buf,this.vew=new DataView(this.buf),this.len=e.length,this.position=e.position),null!=e&&void 0!=e&&e instanceof ArrayBuffer&&(this.buf=e,this.vew=new DataView(this.buf),this.len=this.vew.byteLength,this.position=0),this.__defineGetter__("length",function(){return this.len}),this.__defineGetter__("buffer",function(){return this.buf})},hM.BinBuffer.prototype._write=function(e,t,n){return e.writeBytes(t,n)},hM.BinBuffer.prototype._read=function(e,t,n){return e.readBytes(t,!0,n)},hM.BinBuffer.prototype._clone=function(){return new hM.BinBuffer},hM.BinBuffer.prototype.allocate=function(e){if(e=this.position+e,null==this.buf||!(this.buf.length>e)){var t=new ArrayBuffer(Math.max(256,2*e));null!=this.buf&&(new Uint8Array(t).set(new Uint8Array(this.buf)),this.buf=void 0),this.buf=t,this.vew=void 0,this.vew=new DataView(this.buf)}},hM.BinBuffer.prototype.getBuffer=function(){var e=new ArrayBuffer(this.len);return new Uint8Array(e).set(new Uint8Array(this.buf,0,this.len)),e},hM.BinBuffer.prototype.memset=function(e,t,n){this.allocate(n),new Uint8Array(this.buf).set(new Uint8Array(e,t,n),this.position)},hM.BinBuffer.prototype.writeInt8=function(e){this.allocate(1),this.vew.setInt8(this.position,e),this.position+=1,this.len=this.position},hM.BinBuffer.prototype.writeUInt8=function(e){this.allocate(1),this.vew.setUint8(this.position++,e),this.len=this.position},hM.BinBuffer.prototype.writeInt16=function(e){this.allocate(2),this.vew.setInt16(this.position,e),this.position+=2,this.len=this.position},hM.BinBuffer.prototype.writeUInt16=function(e){this.allocate(2),this.vew.setUint16(this.position,e),this.position+=2,this.len=this.position},hM.BinBuffer.prototype.writeInt32=function(e){this.allocate(4),this.vew.setInt32(this.position,e),this.position+=4,this.len=this.position},hM.BinBuffer.prototype.writeUInt32=function(e){this.allocate(4),this.vew.setUint32(this.position,e),this.position+=4,this.len=this.position},hM.BinBuffer.prototype.writeInt64=function(e){if("string"==typeof e){this.allocate(8),e=e.toLowerCase();for(var t=0,n=0,r=0;r<e.length;r++){var i=e.charCodeAt(r)-48;i>9&&(i-=39),n=10*n+Math.floor((t=10*t+i)/0x100000000),t%=0x100000000}this.vew.setUint32(this.position,n),this.vew.setUint32(this.position+4,t),this.position+=8,this.len=this.position;return}this.allocate(8),this.vew.setUint32(this.position,parseInt(e/0x100000000)),this.vew.setUint32(this.position+4,e%0x100000000),this.position+=8,this.len=this.position},hM.BinBuffer.prototype.writeFloat=function(e){this.allocate(4),this.vew.setFloat32(this.position,e),this.position+=4,this.len=this.position},hM.BinBuffer.prototype.writeDouble=function(e){this.allocate(8),this.vew.setFloat64(this.position,e),this.position+=8,this.len=this.position},hM.BinBuffer.prototype.writeString=function(e){for(var t=[],n=0;n<e.length;n++)t.push(255&e.charCodeAt(n));this.allocate(t.length),new Uint8Array(this.buf).set(new Uint8Array(t),this.position),this.position+=t.length,this.len=this.position},hM.BinBuffer.prototype.writeBytes=function(e){0!=e.length&&null!=e.buf&&(this.allocate(e.length),new Uint8Array(this.buf).set(new Uint8Array(e.buf,0,e.length),this.position),this.position+=e.length,this.len=this.position)},hM.BinBuffer.prototype.readInt8=function(){return this.vew.getInt8(this.position++)},hM.BinBuffer.prototype.readInt16=function(){return this.position+=2,this.vew.getInt16(this.position-2)},hM.BinBuffer.prototype.readInt32=function(){return this.position+=4,this.vew.getInt32(this.position-4)},hM.BinBuffer.prototype.readUInt8=function(){return this.position+=1,this.vew.getUint8(this.position-1)},hM.BinBuffer.prototype.readUInt16=function(){return this.position+=2,this.vew.getUint16(this.position-2)},hM.BinBuffer.prototype.readUInt32=function(){return this.position+=4,this.vew.getUint32(this.position-4)},hM.BinBuffer.prototype.readInt64=function(){var e,t,n,r=this.vew.getUint32(this.position),i=this.vew.getUint32(this.position+4);this.position+=8;for(var a="";0!=r||0!=i;)a=(t=(n=0x100000000*(e=r%10)+i)%10).toString(10)+a,r=(r-e)/10,i=(n-t)/10;return a},hM.BinBuffer.prototype.readFloat=function(){var e=this.vew.getFloat32(this.position);return this.position+=4,e},hM.BinBuffer.prototype.readDouble=function(){var e=this.vew.getFloat64(this.position);return this.position+=8,e},hM.BinBuffer.prototype.readString=function(e){for(var t=[],n=0;n<e;n++)t.push(String.fromCharCode(this.vew.getUint8(this.position++)));var r=t.join("");try{r=decodeURIComponent(escape(r))}catch(e){}return r.replace(/</g,"<").replace(/>/g,">").replace(/\'/g,"'").replace(/\"/g,""")},hM.BinBuffer.prototype.readBytes=function(e){var t=new hM.BinBuffer;return t.allocate(e),t.memset(this.buf,this.position,e),t.position=0,t.len=e,this.position=this.position+e,t},hM.JceOutputStream=function(){this.buf=new hM.BinBuffer,this.getBinBuffer=function(){return this.buf},this.getBuffer=function(){return this.buf.getBuffer()}},hM.JceOutputStream.prototype.clear=function(){return this.buf=new hM.BinBuffer,this},hM.JceOutputStream.prototype.writeTo=function(e,t){e<15?this.buf.writeUInt8(e<<4&240|t):this.buf.writeUInt16((240|t)<<8|e)},hM.JceOutputStream.prototype.writeBoolean=function(e,t){this.writeInt8(e,+(!0==t))},hM.JceOutputStream.prototype.writeInt8=function(e,t){0==t?this.writeTo(e,hM.DataHelp.EN_ZERO):(this.writeTo(e,hM.DataHelp.EN_INT8),this.buf.writeInt8(t))},hM.JceOutputStream.prototype.writeInt16=function(e,t){t>=-128&&t<=127?this.writeInt8(e,t):(this.writeTo(e,hM.DataHelp.EN_INT16),this.buf.writeInt16(t))},hM.JceOutputStream.prototype.writeInt32=function(e,t){t>=-32768&&t<=32767?this.writeInt16(e,t):(this.writeTo(e,hM.DataHelp.EN_INT32),this.buf.writeInt32(t))},hM.JceOutputStream.prototype.writeInt64=function(e,t){t>=-0x80000000&&t<=0x7fffffff?this.writeInt32(e,t):(this.writeTo(e,hM.DataHelp.EN_INT64),this.buf.writeInt64(t))},hM.JceOutputStream.prototype.writeUInt8=function(e,t){this.writeInt16(e,t)},hM.JceOutputStream.prototype.writeUInt16=function(e,t){this.writeInt32(e,t)},hM.JceOutputStream.prototype.writeUInt32=function(e,t){this.writeInt64(e,t)},hM.JceOutputStream.prototype.writeFloat=function(e,t){0==t?this.writeTo(e,hM.DataHelp.EN_ZERO):(this.writeTo(e,hM.DataHelp.EN_FLOAT),this.buf.writeFloat(t))},hM.JceOutputStream.prototype.writeDouble=function(e,t){0==t?this.writeTo(e,hM.DataHelp.EN_ZERO):(this.writeTo(e,hM.DataHelp.EN_DOUBLE),this.buf.writeDouble(t))},hM.JceOutputStream.prototype.writeStruct=function(e,t){if(void 0==t.writeTo)throw Error("not defined writeTo Function");this.writeTo(e,hM.DataHelp.EN_STRUCTBEGIN),t.writeTo(this),this.writeTo(0,hM.DataHelp.EN_STRUCTEND)},hM.JceOutputStream.prototype.writeString=function(e,t){var n=t;try{n=unescape(encodeURIComponent(n))}catch(e){}n.length>255?(this.writeTo(e,hM.DataHelp.EN_STRING4),this.buf.writeUInt32(n.length)):(this.writeTo(e,hM.DataHelp.EN_STRING1),this.buf.writeUInt8(n.length)),this.buf.writeString(n)},hM.JceOutputStream.prototype.writeBytes=function(e,t){if(!(t instanceof hM.BinBuffer))throw Error("value not instanceof Taf.BinBuffer");this.writeTo(e,hM.DataHelp.EN_SIMPLELIST),this.writeTo(0,hM.DataHelp.EN_INT8),this.writeInt32(0,t.length),this.buf.writeBytes(t)},hM.JceOutputStream.prototype.writeVector=function(e,t){this.writeTo(e,hM.DataHelp.EN_LIST),this.writeInt32(0,t.value.length);for(var n=0;n<t.value.length;n++)t.proto._write(this,0,t.value[n])},hM.JceOutputStream.prototype.writeMap=function(e,t){for(var n in this.writeTo(e,hM.DataHelp.EN_MAP),this.writeInt32(0,t.size()),t.value)t.kproto._write(this,0,n),t.vproto._write(this,1,t.value[n])},hM.JceInputStream=function(e){this.buf=new hM.BinBuffer(e)},hM.JceInputStream.prototype.setBuffer=function(e){return this.buf=new hM.BinBuffer(e),this},hM.JceInputStream.prototype.readFrom=function(){var e=this.buf.readUInt8(),t=(240&e)>>4;return t>=15&&(t=this.buf.readUInt8()),{tag:t,type:15&e}},hM.JceInputStream.prototype.peekFrom=function(){var e=this.buf.position,t=this.readFrom();return this.buf.position=e,{tag:t.tag,type:t.type,size:t.tag>=15?2:1}},hM.JceInputStream.prototype.skipField=function(e){switch(e){case hM.DataHelp.EN_INT8:this.buf.position+=1;break;case hM.DataHelp.EN_INT16:this.buf.position+=2;break;case hM.DataHelp.EN_INT32:this.buf.position+=4;break;case hM.DataHelp.EN_INT64:this.buf.position+=8;break;case hM.DataHelp.EN_STRING1:var t=this.buf.readUInt8();this.buf.position+=t;break;case hM.DataHelp.EN_STRING4:var n=this.buf.readInt32();this.buf.position+=n;break;case hM.DataHelp.EN_STRUCTBEGIN:this.skipToStructEnd();break;case hM.DataHelp.EN_STRUCTEND:case hM.DataHelp.EN_ZERO:break;case hM.DataHelp.EN_MAP:for(var r=this.readInt32(0,!0),i=0;i<2*r;++i){var a=this.readFrom();this.skipField(a.type)}break;case hM.DataHelp.EN_SIMPLELIST:var a=this.readFrom();if(a.type!=hM.DataHelp.EN_INT8)throw Error("skipField with invalid type, type value: "+e+","+a.type);var t=this.readInt32(0,!0);this.buf.position+=t;break;case hM.DataHelp.EN_LIST:for(var r=this.readInt32(0,!0),i=0;i<r;++i){var a=this.readFrom();this.skipField(a.type)}break;default:throw Error("skipField with invalid type, type value: "+e)}},hM.JceInputStream.prototype.skipToStructEnd=function(){for(;;){var e=this.readFrom();if(this.skipField(e.type),e.type==hM.DataHelp.EN_STRUCTEND)return}},hM.JceInputStream.prototype.skipToTag=function(e,t){for(;this.buf.position<this.buf.length;){var n=this.peekFrom();if(e<=n.tag||n.type==hM.DataHelp.EN_STRUCTEND)return n.type!=hM.DataHelp.EN_STRUCTEND&&e==n.tag;this.buf.position+=n.size,this.skipField(n.type)}if(t)throw Error("require field not exist, tag:"+e);return!1},hM.JceInputStream.prototype.readBoolean=function(e,t,n){return 1==this.readInt8(e,t,n)},hM.JceInputStream.prototype.readInt8=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();switch(r.type){case hM.DataHelp.EN_ZERO:return 0;case hM.DataHelp.EN_INT8:return this.buf.readInt8()}throw Error("read int8 type mismatch, tag:"+e+", get type:"+r.type)},hM.JceInputStream.prototype.readInt16=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();switch(r.type){case hM.DataHelp.EN_ZERO:return 0;case hM.DataHelp.EN_INT8:return this.buf.readInt8();case hM.DataHelp.EN_INT16:return this.buf.readInt16()}throw Error("read int16 type mismatch, tag:"+e+", get type:"+r.type)},hM.JceInputStream.prototype.readInt32=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();switch(r.type){case hM.DataHelp.EN_ZERO:return 0;case hM.DataHelp.EN_INT8:return this.buf.readInt8();case hM.DataHelp.EN_INT16:return this.buf.readInt16();case hM.DataHelp.EN_INT32:return this.buf.readInt32()}throw Error("read int32 type mismatch, tag:"+e+", get type:"+r.type)},hM.JceInputStream.prototype.readInt64=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();switch(r.type){case hM.DataHelp.EN_ZERO:return 0;case hM.DataHelp.EN_INT8:return this.buf.readInt8();case hM.DataHelp.EN_INT16:return this.buf.readInt16();case hM.DataHelp.EN_INT32:return this.buf.readInt32();case hM.DataHelp.EN_INT64:return this.buf.readInt64()}throw Error("read int64 type mismatch, tag:"+e+", get type:"+r.type)},hM.JceInputStream.prototype.readFloat=function(e,t,n){if(!1==this.skipToTag(e,t))return n;switch(this.readFrom().type){case hM.DataHelp.EN_ZERO:return 0;case hM.DataHelp.EN_FLOAT:return this.buf.readFloat()}throw Error("read float type mismatch, tag:"+e+", get type:"+ij.type)},hM.JceInputStream.prototype.readDouble=function(e,t,n){if(!1==this.skipToTag(e,t))return n;switch(this.readFrom().type){case hM.DataHelp.EN_ZERO:return 0;case hM.DataHelp.EN_DOUBLE:return this.buf.readDouble()}throw Error("read double type mismatch, tag:"+e+", get type:"+ij.type)},hM.JceInputStream.prototype.readUInt8=function(e,t,n){return this.readInt16(e,t,n)},hM.JceInputStream.prototype.readUInt16=function(e,t,n){return this.readInt32(e,t,n)},hM.JceInputStream.prototype.readUInt32=function(e,t,n){return this.readInt64(e,t,n)},hM.JceInputStream.prototype.readStruct=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();if(r.type!=hM.DataHelp.EN_STRUCTBEGIN)throw Error("read struct type mismatch, tag: "+e+", get type:"+r.type);return n.readFrom(this),this.skipToStructEnd(),n},hM.JceInputStream.prototype.readString=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();if(r.type==hM.DataHelp.EN_STRING1)return this.buf.readString(this.buf.readUInt8());if(r.type==hM.DataHelp.EN_STRING4)return this.buf.readString(this.buf.readUInt32());throw Error("read 'string' type mismatch, tag: "+e+", get type: "+r.type+".")},hM.JceInputStream.prototype.readString2=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();if(r.type==hM.DataHelp.EN_STRING1)return this.buf.readBytes(this.buf.readUInt8());if(r.type==hM.DataHelp.EN_STRING4)return this.buf.readBytes(this.buf.readUInt32());throw Error("read 'string2' type mismatch, tag: "+e+", get type: "+r.type+".")},hM.JceInputStream.prototype.readBytes=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();if(r.type==hM.DataHelp.EN_SIMPLELIST){var i=this.readFrom();if(i.type!=hM.DataHelp.EN_INT8)throw Error("type mismatch, tag:"+e+",type:"+r.type+","+i.type);var a=this.readInt32(0,!0);if(a<0)throw Error("invalid size, tag:"+e+",type:"+r.type+","+i.type);return this.buf.readBytes(a)}if(r.type==hM.DataHelp.EN_LIST){var a=this.readInt32(0,!0);return this.buf.readBytes(a)}throw Error("type mismatch, tag:"+e+",type:"+r.type)},hM.JceInputStream.prototype.readVector=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();if(r.type!=hM.DataHelp.EN_LIST)throw Error("read 'vector' type mismatch, tag: "+e+", get type: "+r.type);var i=this.readInt32(0,!0);if(i<0)throw Error("invalid size, tag: "+e+", type: "+r.type+", size: "+i);for(var a=0;a<i;++a)n.value.push(n.proto._read(this,0,n.proto._clone()));return n},hM.JceInputStream.prototype.readMap=function(e,t,n){if(!1==this.skipToTag(e,t))return n;var r=this.readFrom();if(r.type!=hM.DataHelp.EN_MAP)throw Error("read 'map' type mismatch, tag: "+e+", get type: "+r.type);var i=this.readInt32(0,!0);if(i<0)throw Error("invalid map, tag: "+e+", size: "+i);for(var a=0;a<i;a++){var s=n.kproto._read(this,0,n.kproto._clone()),l=n.vproto._read(this,1,n.vproto._clone());n.put(s,l)}return n},hM.Wup=function(){this.iVersion=3,this.cPacketType=0,this.iMessageType=0,this.iRequestId=0,this.sServantName="",this.sFuncName="",this.sBuffer=new hM.BinBuffer,this.iTimeout=0,this.context=new hM.Map(new hM.STRING,new hM.STRING),this.status=new hM.Map(new hM.STRING,new hM.STRING),this.newdata=new hM.Map(new hM.STRING,new hM.BinBuffer),this.iStream=new hM.JceInputStream,this.oStream=new hM.JceOutputStream},hM.Wup.prototype.hasKey=function(e){return this.newdata.hasKey(e)},hM.Wup.prototype.setVersion=function(e){this.iVersion=e},hM.Wup.prototype.getVersion=function(e){return this.iVersion},hM.Wup.prototype.setServant=function(e){this.sServantName=e},hM.Wup.prototype.setFunc=function(e){this.sFuncName=e},hM.Wup.prototype.setRequestId=function(e){this.iRequestId=e||++this.iRequestId},hM.Wup.prototype.getRequestId=function(){return this.iRequestId},hM.Wup.prototype.setTimeOut=function(e){this.iTimeout=e},hM.Wup.prototype.getTimeOut=function(){return this.iTimeout},hM.Wup.prototype.writeTo=function(){var e=this.oStream.clear();return e.writeInt16(1,this.iVersion),e.writeInt8(2,this.cPacketType),e.writeInt32(3,this.iMessageType),e.writeInt32(4,this.iRequestId),e.writeString(5,this.sServantName),e.writeString(6,this.sFuncName),e.writeBytes(7,this.sBuffer),e.writeInt32(8,this.iTimeout),e.writeMap(9,this.context),e.writeMap(10,this.status),new hM.BinBuffer(e.getBuffer())},hM.Wup.prototype.encode=function(){var e=this.oStream.clear();e.writeMap(0,this.newdata),this.sBuffer=e.getBinBuffer();var t=this.writeTo(),n=new hM.BinBuffer;return n.writeInt32(4+t.len),n.writeBytes(t),n},hM.Wup.prototype.writeBoolean=function(e,t){var n=this.oStream.clear();n.writeBoolean(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeInt8=function(e,t){var n=this.oStream.clear();n.writeInt8(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeInt16=function(e,t){var n=this.oStream.clear();n.writeInt16(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeInt32=function(e,t){var n=this.oStream.clear();n.writeInt32(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeInt64=function(e,t){var n=this.oStream.clear();n.writeInt64(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeFloat=function(e,t){var n=this.oStream.clear();n.writeFloat(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeDouble=function(e,t){var n=this.oStream.clear();n.writeDouble(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeString=function(e,t){var n=this.oStream.clear();n.writeString(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeVector=function(e,t){var n=this.oStream.clear();n.writeVector(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBinBuffer()))},hM.Wup.prototype.writeStruct=function(e,t){var n=this.oStream.clear();n.writeStruct(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeBytes=function(e,t){var n=this.oStream.clear();n.writeBytes(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.writeMap=function(e,t){var n=this.oStream.clear();n.writeMap(0,t),this.newdata.put(e,new hM.BinBuffer(n.getBuffer()))},hM.Wup.prototype.readFrom=function(e){this.iVersion=e.readInt16(1,!0),this.cPacketType=e.readInt8(2,!0),this.iMessageType=e.readInt32(3,!0),this.iRequestId=e.readInt32(4,!0),this.sServantName=e.readString(5,!0),this.sFuncName=e.readString(6,!0),this.sBuffer=e.readBytes(7,!0),this.iTimeout=e.readInt32(8,!0),this.context=e.readMap(9,!0,this.context),this.status=e.readMap(10,!0,this.status)},hM.Wup.prototype.decode=function(e){var t=this.iStream.setBuffer(e);if(4>t.buf.vew.getInt32(t.buf.position))throw Error("packet length too short");t.buf.position+=4,this.readFrom(t),t=this.iStream.setBuffer(this.sBuffer.getBuffer()),this.newdata.clear(),t.readMap(0,!0,this.newdata)},hM.Wup.prototype.readBoolean=function(e){var t,n;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return this.iStream.setBuffer(t.buffer).readBoolean(0,!0,n)},hM.Wup.prototype.readInt8=function(e){var t,n;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return this.iStream.setBuffer(t.buffer).readInt8(0,!0,n)},hM.Wup.prototype.readInt16=function(e){var t,n;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return this.iStream.setBuffer(t.buffer).readInt16(0,!0,n)},hM.Wup.prototype.readInt32=function(e){var t,n;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return this.iStream.setBuffer(t.buffer).readInt32(0,!0,n)},hM.Wup.prototype.readInt64=function(e){var t,n;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return this.iStream.setBuffer(t.buffer).readInt64(0,!0,n)},hM.Wup.prototype.readFloat=function(e){var t,n;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return this.iStream.setBuffer(t.buffer).readFloat(0,!0,n)},hM.Wup.prototype.readDouble=function(e){var t;if(void 0==(t=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return def=this.iStream.setBuffer(t.buffer).readDouble(0,!0,def)},hM.Wup.prototype.readVector=function(e,t,n){var r;if(void 0==(r=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return t=this.iStream.setBuffer(r.buffer).readVector(0,!0,t)},hM.Wup.prototype.readStruct=function(e,t,n){var r;if(void 0==(r=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return t=this.iStream.setBuffer(r.buffer).readStruct(0,!0,t)},hM.Wup.prototype.readMap=function(e,t,n){var r;if(void 0==(r=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return t=this.iStream.setBuffer(r.buffer).readMap(0,!0,t)},hM.Wup.prototype.readBytes=function(e,t,n){var r;if(void 0==(r=this.newdata.get(e)))throw Error("UniAttribute not found key:"+e);return t=this.iStream.setBuffer(r.buffer).readBytes(0,!0,t)},hM.Util=hM.Util||{},hM.Util.jcestream=function(e,t){if(null!=e&&void 0!=e&&e instanceof ArrayBuffer){t=t||16;for(var n=new Uint8Array(e),r="",i=0;i<n.length;i++)0!=i&&i%t==0?r+="\n":0!=i&&(r+=" "),r+=(n[i]>15?"":"0")+n[i].toString(16)}},hM.Util.str2ab=function(e){var t,n=e.length,r=Array(n);for(t=0;t<n;++t)r[t]=e.charCodeAt(t);return new Uint8Array(r).buffer},hM.Util.ajax=function(e,t,n,r){var i=new XMLHttpRequest;i.overrideMimeType("text/plain; charset=x-user-defined");var a=function(){4===i.readyState&&(200===i.status||304===i.status?n(hM.Util.str2ab(i.response)):r(i.status),i.removeEventListener("readystatechange",a),i=void 0)};i.addEventListener("readystatechange",a),i.open("post",e),i.send(t)};var hN={};hN.WSRegisterGroupReq=function(){this.vGroupId=new hM.Vector(new hM.STRING),this.sToken=""},hN.WSRegisterGroupReq.prototype.writeTo=function(e){e.writeVector(0,this.vGroupId),e.writeString(1,this.sToken)},hN.UserHeartBeatReq=function(){this.tId=new hN.UserId,this.lTid=0,this.lSid=0,this.lPid=0,this.bWatchVideo=!1,this.eLineType=0,this.iFps=0,this.iAttendee=0,this.iBandwidth=0,this.lShortTid=0,this.iLastHeartElapseTime=0},hN.UserHeartBeatReq.prototype.writeTo=function(e){e.writeStruct(0,this.tId),e.writeInt64(1,this.lTid),e.writeInt64(2,this.lSid),e.writeInt64(4,this.lPid),e.writeBoolean(5,this.bWatchVideo),e.writeInt32(6,this.eLineType),e.writeInt32(7,this.iFps),e.writeInt32(8,this.iAttendee),e.writeInt32(9,this.iBandwidth),e.writeInt32(10,this.iLastHeartElapseTime)},hN.WebSocketCommand=function(){this.iCmdType=0,this.vData=new hM.BinBuffer,this.lRequestId=0,this.traceId=""},hN.WebSocketCommand.prototype.writeTo=function(e){e.writeInt32(0,this.iCmdType),e.writeBytes(1,this.vData),e.writeInt64(2,this.lRequestId),e.writeString(3,this.traceId)},hN.WebSocketCommand.prototype.readFrom=function(e){this.iCmdType=e.readInt32(0,!1,this.iCmdType),this.vData=e.readBytes(1,!1,this.vData),this.lRequestId=e.readInt64(2,!1,this.lRequestId),this.traceId=e.readString(3,!1,this.traceId)},hN.WSPushMessage=function(){this.ePushType=0,this.iUri=0,this.sMsg=new hM.BinBuffer,this.iProtocolType=0,this.sGroupId=""},hN.WSPushMessage.prototype.readFrom=function(e){this.ePushType=e.readInt32(0,!1,this.ePushType),this.iUri=e.readInt64(1,!1,this.iUri),this.sMsg=e.readBytes(2,!1,this.sMsg),this.iProtocolType=e.readInt32(3,!1,this.iProtocolType),this.sGroupId=e.readString(4,!1,this.sGroupId)},hN.MessageNotice=function(){this.tUserInfo=new hN.SenderInfo,this.sContent="",this.sIconUrl=""},hN.MessageNotice.prototype.readFrom=function(e){this.tUserInfo=e.readStruct(0,!1,this.tUserInfo),this.sContent=e.readString(3,!1,this.sContent)},hN.UserId=function(){this.lUid=0,this.sGuid="",this.sToken="",this.sHuYaUA="",this.sCookie="",this.iTokenType=0},hN.UserId.prototype.writeTo=function(e){e.writeInt64(0,this.lUid),e.writeString(1,this.sGuid),e.writeString(2,this.sToken),e.writeString(3,this.sHuYaUA),e.writeString(4,this.sCookie),e.writeInt32(5,this.iTokenType)},hN.UserId.prototype.readFrom=function(e){this.lUid=e.readInt64(0,!1,this.lUid),this.sGuid=e.readString(1,!1,this.sGuid),this.sToken=e.readString(2,!1,this.sToken),this.sHuYaUA=e.readString(3,!1,this.sHuYaUA),this.sCookie=e.readString(4,!1,this.sCookie),this.iTokenType=e.readInt32(5,!1,this.iTokenType)},hN.SenderInfo=function(){this.sNickName=""},hN.SenderInfo.prototype.writeTo=function(e){e.writeString(2,this.sNickName)},hN.SenderInfo.prototype.readFrom=function(e){this.sNickName=e.readString(2,!1,this.sNickName)},hN.ContentFormat=function(){this.iFontColor=-1,this.iFontSize=4,this.iPopupStyle=0},hN.ContentFormat.prototype._clone=function(){return new hN.ContentFormat},hN.ContentFormat.prototype._write=function(e,t,n){e.writeStruct(t,n)},hN.ContentFormat.prototype._read=function(e,t,n){return e.readStruct(t,!0,n)},hN.ContentFormat.prototype.writeTo=function(e){e.writeInt32(0,this.iFontColor),e.writeInt32(1,this.iFontSize),e.writeInt32(2,this.iPopupStyle)},hN.ContentFormat.prototype.readFrom=function(e){this.iFontColor=e.readInt32(0,!1,this.iFontColor),this.iFontSize=e.readInt32(1,!1,this.iFontSize),this.iPopupStyle=e.readInt32(2,!1,this.iPopupStyle)};function hF(e){let t=h1(e),n=e.limit;return e.limit=e.offset+t,n}function hj(e,t){switch(t){case 0:for(;128&hX(e););break;case 2:hW(e,h1(e));break;case 5:hW(e,4);break;case 1:hW(e,8);break;default:throw Error("Unimplemented type: "+t)}}let hz=(new Uint8Array(new Float32Array(1).buffer),new Float64Array(1)),hG=(new Uint8Array(hz.buffer),[]);function hV(){let e=hG.pop();return e?(e.offset=e.limit=0,e):{bytes:new Uint8Array(64),offset:0,limit:0}}function hH(e){return{bytes:e,offset:0,limit:e.length}}function hW(e,t){if(e.offset+t>e.limit)throw Error("Skip past limit");e.offset+=t}function hq(e){return e.offset>=e.limit}function hK(e,t){let n=e.bytes,r=e.offset,i=e.limit,a=r+t;if(a>n.length){let t=new Uint8Array(2*a);t.set(n),e.bytes=t}return e.offset=a,a>i&&(e.limit=a),r}function hJ(e,t){let n=e.offset;if(n+t>e.limit)throw Error("Read past limit");return e.offset+=t,n}function hZ(e,t){let n=hJ(e,t);return e.bytes.subarray(n,n+t)}function h$(e,t){let n=hK(e,t.length);e.bytes.set(t,n)}function hY(e,t){let n=hJ(e,t),r=String.fromCharCode,i=e.bytes,a="";for(let e=0;e<t;e++){let s=i[e+n],l,u,c,d;(128&s)==0?a+=r(s):(224&s)==192?e+1>=t||(192&(l=i[e+n+1]))!=128||(d=(31&s)<<6|63&l)<128?a+="�":(a+=r(d),e++):(240&s)==224?e+2>=t||(((l=i[e+n+1])|(u=i[e+n+2])<<8)&49344)!=32896||(d=(15&s)<<12|(63&l)<<6|63&u)<2048||d>=55296&&d<=57343?a+="�":(a+=r(d),e+=2):(248&s)==240?e+3>=t?a+="�":(l=i[e+n+1],((l|(u=i[e+n+2])<<8|(c=i[e+n+3])<<16)&0xc0c0c0)!=8421504||(d=(7&s)<<18|(63&l)<<12|(63&u)<<6|63&c)<65536||d>1114111?a+="�":(d-=65536,a+=r((d>>10)+55296,(1023&d)+56320),e+=3)):a+="�"}return a}function hQ(e,t){let n=t.length,r=0;for(let e=0;e<n;e++){let i=t.charCodeAt(e);i>=55296&&i<=56319&&e+1<n&&(i=(i<<10)+t.charCodeAt(++e)-0x35fdc00),r+=i<128?1:i<2048?2:i<65536?3:4}h2(e,r);let i=hK(e,r),a=e.bytes;for(let e=0;e<n;e++){let r=t.charCodeAt(e);r>=55296&&r<=56319&&e+1<n&&(r=(r<<10)+t.charCodeAt(++e)-0x35fdc00),r<128?a[i++]=r:(r<2048?a[i++]=r>>6&31|192:(r<65536?a[i++]=r>>12&15|224:(a[i++]=r>>18&7|240,a[i++]=r>>12&63|128),a[i++]=r>>6&63|128),a[i++]=63&r|128)}}function hX(e){return e.bytes[hJ(e,1)]}function h0(e,t){let n=hK(e,1);e.bytes[n]=t}function h1(e){let t,n=0,r=0;do t=hX(e),n<32&&(r|=(127&t)<<n),n+=7;while(128&t);return r}function h2(e,t){for(t>>>=0;t>=128;)h0(e,127&t|128),t>>>=7;h0(e,t)}function h5(e,t){let n,r=0,i=0,a=0;return r=127&(n=hX(e)),128&n&&(r|=(127&(n=hX(e)))<<7,128&n&&(r|=(127&(n=hX(e)))<<14,128&n&&(r|=(127&(n=hX(e)))<<21,128&n&&(i=127&(n=hX(e)),128&n&&(i|=(127&(n=hX(e)))<<7,128&n&&(i|=(127&(n=hX(e)))<<14,128&n&&(i|=(127&(n=hX(e)))<<21,128&n&&(a=127&(n=hX(e)),128&n&&(a|=(127&(n=hX(e)))<<7))))))))),{low:r|i<<28,high:i>>>4|a<<24,unsigned:t}}function h3(e,t){let n=t.low>>>0,r=(t.low>>>28|t.high<<4)>>>0,i=t.high>>>24,a=0===i?0===r?n<16384?n<128?1:2:n<2097152?3:4:r<16384?r<128?5:6:r<2097152?7:8:i<128?9:10,s=hK(e,a),l=e.bytes;switch(a){case 10:l[s+9]=i>>>7&1;case 9:l[s+8]=9!==a?128|i:127&i;case 8:l[s+7]=8!==a?r>>>21|128:r>>>21&127;case 7:l[s+6]=7!==a?r>>>14|128:r>>>14&127;case 6:l[s+5]=6!==a?r>>>7|128:r>>>7&127;case 5:l[s+4]=5!==a?128|r:127&r;case 4:l[s+3]=4!==a?n>>>21|128:n>>>21&127;case 3:l[s+2]=3!==a?n>>>14|128:n>>>14&127;case 2:l[s+1]=2!==a?n>>>7|128:n>>>7&127;case 1:l[s]=1!==a?128|n:127&n}}var h6=function(e,t){e.constructor==String?e=t&&"binary"===t.encoding?pe(e):pt(e):o(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var n=pn(e),r=8*e.length,i=0x67452301,a=-0x10325477,s=-0x67452302,l=0x10325476,u=0;u<n.length;u++)n[u]=(n[u]<<8|n[u]>>>24)&0xff00ff|(n[u]<<24|n[u]>>>8)&0xff00ff00;n[r>>>5]|=128<<r%32,n[(r+64>>>9<<4)+14]=r;for(var u=0;u<n.length;u+=16){var c=i,d=a,f=s,h=l;i=h4(i,a,s,l,n[u+0],7,-0x28955b88),l=h4(l,i,a,s,n[u+1],12,-0x173848aa),s=h4(s,l,i,a,n[u+2],17,0x242070db),a=h4(a,s,l,i,n[u+3],22,-0x3e423112),i=h4(i,a,s,l,n[u+4],7,-0xa83f051),l=h4(l,i,a,s,n[u+5],12,0x4787c62a),s=h4(s,l,i,a,n[u+6],17,-0x57cfb9ed),a=h4(a,s,l,i,n[u+7],22,-0x2b96aff),i=h4(i,a,s,l,n[u+8],7,0x698098d8),l=h4(l,i,a,s,n[u+9],12,-0x74bb0851),s=h4(s,l,i,a,n[u+10],17,-42063),a=h4(a,s,l,i,n[u+11],22,-0x76a32842),i=h4(i,a,s,l,n[u+12],7,0x6b901122),l=h4(l,i,a,s,n[u+13],12,-0x2678e6d),s=h4(s,l,i,a,n[u+14],17,-0x5986bc72),a=h4(a,s,l,i,n[u+15],22,0x49b40821),i=h8(i,a,s,l,n[u+1],5,-0x9e1da9e),l=h8(l,i,a,s,n[u+6],9,-0x3fbf4cc0),s=h8(s,l,i,a,n[u+11],14,0x265e5a51),a=h8(a,s,l,i,n[u+0],20,-0x16493856),i=h8(i,a,s,l,n[u+5],5,-0x29d0efa3),l=h8(l,i,a,s,n[u+10],9,0x2441453),s=h8(s,l,i,a,n[u+15],14,-0x275e197f),a=h8(a,s,l,i,n[u+4],20,-0x182c0438),i=h8(i,a,s,l,n[u+9],5,0x21e1cde6),l=h8(l,i,a,s,n[u+14],9,-0x3cc8f82a),s=h8(s,l,i,a,n[u+3],14,-0xb2af279),a=h8(a,s,l,i,n[u+8],20,0x455a14ed),i=h8(i,a,s,l,n[u+13],5,-0x561c16fb),l=h8(l,i,a,s,n[u+2],9,-0x3105c08),s=h8(s,l,i,a,n[u+7],14,0x676f02d9),a=h8(a,s,l,i,n[u+12],20,-0x72d5b376),i=h9(i,a,s,l,n[u+5],4,-378558),l=h9(l,i,a,s,n[u+8],11,-0x788e097f),s=h9(s,l,i,a,n[u+11],16,0x6d9d6122),a=h9(a,s,l,i,n[u+14],23,-0x21ac7f4),i=h9(i,a,s,l,n[u+1],4,-0x5b4115bc),l=h9(l,i,a,s,n[u+4],11,0x4bdecfa9),s=h9(s,l,i,a,n[u+7],16,-0x944b4a0),a=h9(a,s,l,i,n[u+10],23,-0x41404390),i=h9(i,a,s,l,n[u+13],4,0x289b7ec6),l=h9(l,i,a,s,n[u+0],11,-0x155ed806),s=h9(s,l,i,a,n[u+3],16,-0x2b10cf7b),a=h9(a,s,l,i,n[u+6],23,0x4881d05),i=h9(i,a,s,l,n[u+9],4,-0x262b2fc7),l=h9(l,i,a,s,n[u+12],11,-0x1924661b),s=h9(s,l,i,a,n[u+15],16,0x1fa27cf8),a=h9(a,s,l,i,n[u+2],23,-0x3b53a99b),i=h7(i,a,s,l,n[u+0],6,-0xbd6ddbc),l=h7(l,i,a,s,n[u+7],10,0x432aff97),s=h7(s,l,i,a,n[u+14],15,-0x546bdc59),a=h7(a,s,l,i,n[u+5],21,-0x36c5fc7),i=h7(i,a,s,l,n[u+12],6,0x655b59c3),l=h7(l,i,a,s,n[u+3],10,-0x70f3336e),s=h7(s,l,i,a,n[u+10],15,-1051523),a=h7(a,s,l,i,n[u+1],21,-0x7a7ba22f),i=h7(i,a,s,l,n[u+8],6,0x6fa87e4f),l=h7(l,i,a,s,n[u+15],10,-0x1d31920),s=h7(s,l,i,a,n[u+6],15,-0x5cfebcec),a=h7(a,s,l,i,n[u+13],21,0x4e0811a1),i=h7(i,a,s,l,n[u+4],6,-0x8ac817e),l=h7(l,i,a,s,n[u+11],10,-0x42c50dcb),s=h7(s,l,i,a,n[u+2],15,0x2ad7d2bb),a=h7(a,s,l,i,n[u+9],21,-0x14792c6f),i=i+c>>>0,a=a+d>>>0,s=s+f>>>0,l=l+h>>>0}return pi([i,a,s,l])};let h4=function(e,t,n,r,i,a,s){var l=e+(t&n|~t&r)+(i>>>0)+s;return(l<<a|l>>>32-a)+t},h8=function(e,t,n,r,i,a,s){var l=e+(t&r|n&~r)+(i>>>0)+s;return(l<<a|l>>>32-a)+t},h9=function(e,t,n,r,i,a,s){var l=e+(t^n^r)+(i>>>0)+s;return(l<<a|l>>>32-a)+t},h7=function(e,t,n,r,i,a,s){var l=e+(n^(t|~r))+(i>>>0)+s;return(l<<a|l>>>32-a)+t},pe=function(e){for(var t=new Uint8Array(e.length),n=0,r=e.length;n<r;n++)t[n]=e.charCodeAt(n);return t},pt=function(e){for(var t=[],n=0;n<e.length;n++)t.push(255&e.charCodeAt(n));return t},pn=function(e){for(var t=[],n=0,r=0;n<e.length;n++,r+=8)t[r>>>5]|=e[n]<<24-r%32;return t},pr=function(e){for(var t=[],n=0;n<32*e.length;n+=8)t.push(e[n>>>5]>>>24-n%32&255);return t},pi=function(e){if(e.constructor==Number)return 0xff00ff&pa(e,8)|0xff00ff00&pa(e,24);for(var t=0;t<e.length;t++)e[t]=pi(e[t]);return e},pa=function(e,t){return e<<t|e>>>32-t},ps=function(e){for(var t=[],n=0;n<e.length;n++)t.push((e[n]>>>4).toString(16)),t.push((15&e[n]).toString(16));return t.join("")},po=(e,t)=>{let n=ps(pr(h6(`,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=${t},device_platform=web,device_type=,ac=,identity=audience`.substring(1))));return window.byted_acrawler.frontierSign({"X-MS-STUB":n})["X-Bogus"]},pl=(e,t)=>{let n,r=tx(),i=new ResizeObserver(e=>{clearTimeout(n),n=setTimeout(()=>{var e;null==(e=r.value)||e.resize()},500)});return nz(()=>{i.observe(e.value),t.canvas=e.value,r.value=new pu(t)}),nH(()=>{i.unobserve(e.value),clearTimeout(n)}),r};class pu{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;let t=Math.floor(2.55*e).toString(16);this.opacityStr=1==t.length?"0"+t:t}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){let t=this.getLine();if(-1==t)return;let n=Math.ceil(this.ctx.measureText(e).width),r=this.canvas.width+n;this.lines[t].width=r,this.textList.push({value:e,width:n,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 e=-1,t=this.lines.length;for(;++e<t;)if(this.lines[e].width==this.canvas.width)return e;return -1}initRows(){this.lines=[];let e=-1,t=this.gap+this.fontSize;for(;++e<this.rows;)this.lines.push({top:this.gap+t*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,t=this.textList.length,n=[];for(;++e<t;){let t=this.textList[e],r=t.left+t.width;if(r<=0)continue;this.ctx.fillStyle=t.color+this.opacityStr;let i=this.lines[t.line];i&&(this.ctx.fillText(t.value,t.left,this.lines[t.line].top),t.left-=this.speed,n.push(t),i.width=Math.max(r,this.canvas.width))}this.textList=n,0==n.length?this.isdraw=!1:requestAnimationFrame(this.draw.bind(this))}constructor(e){aV(this,"canvas",void 0),aV(this,"colors",void 0),aV(this,"ctx",void 0),aV(this,"isdraw",void 0),aV(this,"lines",void 0),aV(this,"textList",void 0),aV(this,"fontSize",void 0),aV(this,"font",void 0),aV(this,"rows",void 0),aV(this,"gap",void 0),aV(this,"speed",void 0),aV(this,"opacity",void 0),aV(this,"opacityStr",void 0),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()}}let pc={class:"w-full h-full flex flex-col lg:flex-row box-border md:pb-2"},pd={class:"lg:grow-5 flex flex-col"},pf={class:"flex p-2 pt-1 gap-2 text-lg md:pr-3"},ph={class:"hover:text-amber grow w-25 box-border text-center truncate text-4 md:text-5 m-0 pr-6 sm:pr-2 lg:pr-0"},pp={class:"aspect-ratio-video"},pv={class:"w-full h-full pos-absolute top-0 z-1 flex justify-center items-center text-6"},pm=["src"],pg={key:0},py={class:"flex items-center gap-4 p-1"},p_={class:"flex items-center gap-4 p-1"},pb={key:1,class:"h-0 w-0"},pw={class:"grow min-h-50 lg:grow-0 lg:w-80 xl:w-100 flex flex-col lg:pr-0 pt-3 lg-pt-12 lg:ml-3 box-border lg:b-l-solid b lg:b-l-gray-7 lg:pl-3"},px={class:"flex items-center line-height-none gap-4 b b-y-solid py-3 b-gray-7 px-4"},pk=["src"],pS={class:"grow-1 w-20"},pE={class:"h-4 truncate"},pT={class:"h-4 flex text-3 items-center gap-1"},pA=["src"],pO={class:"pos-absolute top-0 right-4 text-4 flex flex-col gap-3"},pC=["src"],pI=["href"],pD=["data-id","data-site","href"],pR={class:"flex items-center gap-2"},pU=["src"],pL=["onClick"],pP={class:"flex flex-col b b-solid b-gray-6 rounded-2 px-2"},pB={class:"flex justify-between items-center mx-2 py-2"},pM={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pN={class:"flex justify-between items-center mx-2 py-2"},pF={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pj={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pz={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pG={class:"flex flex-col b b-solid b-gray-6 rounded-2 px-2"},pV={class:"flex justify-between items-center mx-2 py-2"},pH={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pW={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pq={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},pK={class:"flex flex-wrap shadow blur bg-dark p-2 box-border b b-solid b-gray-7 rounded",style:{"box-shadow":"0 6px 15px 0 rgba(0, 0, 0, .5)"}},pJ=["data-color"],pZ={class:"p-3 flex justify-between items-center"},p$=ny({__name:"play",setup(e){let t,n,r,i,a,s,l,u,c=tc({qn:0,line:0,notice:null,paused:!0,muted:!1,fullscreen:!1,webscreen:!1,showController:!0,pictureInPicture:!1}),d=iF(()=>!!f.meta.site.follows[f.meta.id]),f=rp(oW),h=tx(),p=tx(),m=tx(),g=tx(),y=iF(()=>{var e,t;return g.value&&(null==(t=g.value)||null==(e=t.stream)?void 0:e.length)>0?g.value.stream.map(e=>e.name):[]}),_=iF(()=>y.value.length>0?g.value.stream[c.qn].lines.map(e=>e.name):[]),b=iF(()=>_.value.length>0?g.value.stream[c.qn].lines[c.line].url:""),w=iF(()=>sg.map(e=>Object.values(e.follows)).flat().sort(e=>e.status?-1:0)),x=iF(()=>{var e;return(null==(e=g.value)?void 0:e.siteId)=="huya"&&["一起看","星秀","原创"].includes(g.value.category)}),k=()=>{x.value&&(i=setInterval(()=>{let e=ss(g.value.info);c.flv.switchURL(b.value+e,!0)},11e4))};rF(b,()=>{if(clearInterval(i),!b.value)return;let e="huya"==g.value.siteId?b.value+ss(g.value.info):b.value;if(c.flv){var t;return null==(t=c.flv)||t.switchURL(e,!0),k()}if(null==ds?void 0:ds.isSupported("video")){let t=new ds({media:p.value,seamlesslyReload:!0,isLive:!0,retryCount:0});return t.load(e),c.flv=t,k()}return c.notice=`播放失败`,clearTimeout(n)},void 0);let S=()=>{m.value.scrollTop=0,D=0,m.value.innerHTML=""},E=0,T=!0,A=tx(),O=pl(A,{gap:sE.canvasGap,rows:sE.canvasRows,speed:sE.canvasSpeed,opacity:sE.canvasOpacity,colors:sE.canvasColorOpen?sE.colors:["#ffffff"]}),C=[],I=(e,t)=>{var n;if(E++,sE.blockOpen&&sC.value.length&&sC.value.some(e=>e.test(t))||(E%(sE.sideClean||100)==0&&(m.value.innerHTML="",D=0),sE.canvasOpen&&(null==(n=O.value)||n.add(t)),!sR.value||!sE.sideOpen))return;let r=document.createElement("div"),{sideColorOpen:i,sideFontsize:a,sideGap:l,colors:u}=sE;r.style.margin=`${l}px 0`,r.style.fontSize=`${a}px`,i&&(r.style.color=u[Math.floor(Math.random()*u.length)]);let c=document.createElement("span");c.style.opacity="0.5",c.appendChild(document.createTextNode(e+":"));let d=document.createElement("span");d.appendChild(document.createTextNode(t)),r.appendChild(c),r.appendChild(d),C.push(r),s||(s=setTimeout(()=>{let e=-1,t=C.length>5?5:C.length;for(m.value.style.display="none";++e<t;)m.value.appendChild(C[e]);m.value.style.display="block",C.splice(0,5),T&&(m.value.scrollTop=m.value.scrollHeight),s=void 0},200))},D=0,R=()=>{if(m.value.scrollTop>=D)return D=m.value.scrollTop;D=m.value.scrollTop,T=!1,m.value.removeEventListener("scroll",R)},U=()=>{T=!0,m.value.scrollTop=m.value.scrollHeight,m.value.addEventListener("scroll",R,{passive:!1})},L=async()=>{if(a||!sE.canvasOpen&&!sE.sideOpen)return;let e=!0;if("huya"==g.value.siteId){a=new WebSocket("wss://cdnws.api.huya.com");let t=g.value.info;a.binaryType="arraybuffer",a.onopen=()=>{clearInterval(l),I("系统","开始连接弹幕服务器"),m.value.addEventListener("scroll",R);let e=new hN.WSRegisterGroupReq;e.vGroupId.value.push("live:"+t.uid),e.vGroupId.value.push("chat:"+t.uid);let n=new hM.JceOutputStream;e.writeTo(n);let r=new hN.WebSocketCommand;r.iCmdType=16,r.vData=n.getBinBuffer(),n=new hM.JceOutputStream,r.writeTo(n),a.send(n.getBuffer()),l=setInterval(()=>{try{let i=new hN.UserHeartBeatReq;i.lPid=t.yyuid;let s=new hN.UserId;s.sHuYaUA="webh5&2106011457&websocket",s.lUid=t.uid,i.tId=s,i.eLineType=1,i.lShortTid=0,i.bWatchVideo=!0,i.eLineType=3,i.iFps=0,i.iAttendee=0,i.iLastHeartElapseTime=0;var e=new hM.Wup;e.setServant("onlineui"),e.setFunc("OnUserHeartBeat"),e.writeStruct("tReq",i);var n=new hN.WebSocketCommand;n.iCmdType=4,n.vData=e.encode();var r=new hM.JceOutputStream;n.writeTo(r),a.send(r.getBuffer())}catch(e){}},6e4)},a.onmessage=async t=>{try{e&&(I("系统","弹幕服务器连接成功"),e=!1);var n=new Uint8Array(t.data).buffer,r=new hM.JceInputStream(n),i=new hN.WebSocketCommand;if(i.readFrom(r),7!=i.iCmdType)return;r=new hM.JceInputStream(i.vData.buf);var a=new hN.WSPushMessage;a.readFrom(r);var s=a.iUri;if(r=new hM.JceInputStream(a.sMsg.buf),1400!=s)return;var l=new hN.MessageNotice;l.readFrom(r),I(l.tUserInfo.sNickName,l.sContent)}catch(e){}},a.onerror=()=>{clearInterval(l),I("系统","弹幕服务器连接失败")},a.onclose=()=>clearInterval(l)}else if("douyu"==g.value.siteId)(a=new WebSocket("wss://danmuproxy.douyu.com:8506")).onopen=()=>{var e,t;clearInterval(l),I("系统","开始连接弹幕服务器"),m.value.addEventListener("scroll",R),a.send(B(`type@=loginreq/roomid@=${null==(e=g.value)?void 0:e.roomId}`)),a.send(B(`type@=joingroup/rid@=${null==(t=g.value)?void 0:t.roomId}/gid@=-9999`)),l=setInterval(()=>{a.send(B("type@=mrkl/"))},45e3)},a.onmessage=async t=>{let{data:n}=t;e&&(I("系统","弹幕服务器连接成功"),e=!1),(await n.text()).split(/type@=chatmsg\//).forEach(e=>{let t=e.match(/nn@=(.*)\/txt@=(.*)\/cid/);null!=t&&I(t[1],t[2])})},a.onerror=()=>{clearInterval(l),I("系统","弹幕服务器连接失败")};else if("douyin"==g.value.siteId){let t=g.value.ws.split(","),n=t[0],r=t[1],i=po(n,r);(a=new WebSocket(`wss://webcast5-ws-web-lf.douyin.com/webcast/im/push/v2/?room_id=${n}&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=${i}&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`)).binaryType="arraybuffer",a.onopen=()=>{clearInterval(l),I("系统","开始连接弹幕服务器"),m.value.addEventListener("scroll",R),l=setInterval(()=>{if((null==a?void 0:a.readyState)==1){var e;let t,n,r;a.send((function(e,t){let n=e.seqId;void 0!==n&&(h2(t,8),h3(t,n));let r=e.logId;void 0!==r&&(h2(t,16),h3(t,r));let i=e.service;void 0!==i&&(h2(t,24),h3(t,i));let a=e.method;void 0!==a&&(h2(t,32),h3(t,a));let s=e.headersList;if(void 0!==s)for(let e of s){var l;h2(t,42);let n=hV();(function(e,t){let n=e.key;void 0!==n&&(h2(t,10),hQ(t,n));let r=e.value;void 0!==r&&(h2(t,18),hQ(t,r))})(e,n),h2(t,n.limit),function(e,t){let n=hK(e,t.limit),r=e.bytes,i=t.bytes;for(let e=0,a=t.limit;e<a;e++)r[e+n]=i[e]}(t,n),l=n,hG.push(l)}let u=e.payloadEncoding;void 0!==u&&(h2(t,50),hQ(t,u));let c=e.payloadType;void 0!==c&&(h2(t,58),hQ(t,c));let d=e.payload;void 0!==d&&(h2(t,66),h2(t,d.length),h$(t,d))}({payloadType:"bh"},t=hV()),n=(e=t).bytes,r=e.limit,n.length===r?n:n.subarray(0,r)))}},1e4)},a.onmessage=t=>{e&&(I("系统","弹幕服务器连接成功"),e=!1);let n=hB(function(e){let t={};n:for(;!hq(e);){let n=h1(e);switch(n>>>3){case 0:break n;case 1:t.seqId=h5(e,!0);break;case 2:t.logId=h5(e,!0);break;case 3:t.service=h5(e,!0);break;case 4:t.method=h5(e,!0);break;case 5:{let n=hF(e);(t.headersList||(t.headersList=[])).push(function(e){let t={};n:for(;!hq(e);){let n=h1(e);switch(n>>>3){case 0:break n;case 1:t.key=hY(e,h1(e));break;case 2:t.value=hY(e,h1(e));break;default:hj(e,7&n)}}return t}(e)),e.limit=n;break}case 6:t.payloadEncoding=hY(e,h1(e));break;case 7:t.payloadType=hY(e,h1(e));break;case 8:t.payload=hZ(e,h1(e));break;default:hj(e,7&n)}}return t}(hH(new Uint8Array(t.data))).payload),r=function(e){let t={};n:for(;!hq(e);){let n=h1(e);switch(n>>>3){case 0:break n;case 1:{let n=hF(e);(t.messagesList||(t.messagesList=[])).push(function(e){let t={};n:for(;!hq(e);){let n=h1(e);switch(n>>>3){case 0:break n;case 1:t.method=hY(e,h1(e));break;case 2:t.payload=hZ(e,h1(e));break;case 3:t.msgId=h5(e,!1);break;case 4:t.msgType=h1(e);break;case 5:t.offset=h5(e,!1);break;case 6:t.needWrdsStore=!!hX(e);break;case 7:t.wrdsVersion=h5(e,!1);break;case 8:t.wrdsSubKey=hY(e,h1(e));break;default:hj(e,7&n)}}return t}(e)),e.limit=n;break}case 8:t.heartbeatDuration=h5(e,!0);break;case 9:t.needAck=!!hX(e);break;default:hj(e,7&n)}}return t}(hH(new Uint8Array(n))).messagesList;if(!r||0==r.length)return;let i=r.length,a=-1;for(;++a<i;){if("WebcastChatMessage"!=r[a].method)continue;let e=function(e){let t={};n:for(;!hq(e);){let n=h1(e);switch(n>>>3){case 0:break n;case 2:{let n=hF(e);t.user=function(e){let t={};n:for(;!hq(e);){let n=h1(e);switch(n>>>3){case 0:break n;case 3:t.nickName=hY(e,h1(e));break;default:hj(e,7&n)}}return t}(e),e.limit=n;break}case 3:t.content=hY(e,h1(e));break;default:hj(e,7&n)}}return t}(hH(r[a].payload));I(e.user.nickName,e.content)}},a.onerror=function(){clearInterval(l),I("系统","弹幕服务器连接失败")}}},P=new TextEncoder;function B(e){let t=P.encode(e),n=9+t.byteLength,r=new Uint8Array(12+(t=P.encode(e+"\0")).byteLength);return r.set([n,0,0,.1,n,0,0,0,177,2,0,0]),r.set(t,12),r.buffer}let M=()=>{clearInterval(l),a&&(a.onmessage=null,"douyu"==Z?a.send(B("type@=logout")):a.close(),a=null,E=0,m.value&&J==f.fullPath&&I("系统","弹幕服务器断开连接"))};rF(g,()=>L(),void 0),rF([()=>sE.sideOpen,()=>sE.canvasOpen],()=>{sE.sideOpen||sE.canvasOpen||M(),a||L()},void 0);let N=()=>{let{site:e,id:t}=f.meta;clearInterval(i),clearInterval(l),clearTimeout(n),c.notice="加载中...",tW(()=>{I("系统","开始获取直播间信息")}),sd(e.id,"getRoomDetail",{id:t}).then(e=>{if(g.value=e,d.value&&(g.value.id=sq(e)),tW(()=>I("系统","直播间信息获取成功")),!e.status)return c.notice="未开播!";document.title=g.value.title},e=>{c.notice=e,tW(()=>I("系统","直播间信息获取失败"))}).finally(()=>clearTimeout(n))},F=()=>{g.value&&(d.value?sK(g.value):sW(g.value))},j=()=>{g.value&&g.value.status&&(clearTimeout(t),t=setTimeout(()=>{c.paused?p.value.play():p.value.pause()},200))},z=()=>{clearTimeout(t),c.fullscreen=!c.fullscreen,document.fullscreenElement?document.exitFullscreen():h.value.requestFullscreen()},G=()=>{clearTimeout(r),c.showController=!0,r=setTimeout(()=>{var e,t;(null==(e=p.value)||!e.paused)&&(null==(t=p.value)?void 0:t.played.length)&&(c.showController=!1)},3e3)},V=()=>{clearTimeout(t),c.webscreen=!c.webscreen,c.fullscreen&&(c.fullscreen=!1,document.exitFullscreen())},H=()=>{c.paused=!1,G()},W=()=>{c.paused=!0,G()},q=e=>{if(b.value)switch(e.code){case"ArrowDown":return sw(!1);case"ArrowUp":return sw(!0);case"Space":return j()}};N();let K=rp(oH),J=f.fullPath;nz(()=>{h.value.style.filter=100==sb.value?"":`brightness(${sb.value/100})`,p.value.volume=s_.value/100,c.muted=p.value.muted,p.value.addEventListener("canplay",()=>{c.notice=null}),l0||(h.value.addEventListener("mousemove",G),document.addEventListener("keydown",q)),document.pictureInPictureElement&&document.exitPictureInPicture(),p.value.addEventListener("leavepictureinpicture",()=>{var e;return/play/.test(f.path)?f.fullPath==J?c.pictureInPicture=!1:void(null==(e=c.flv)||e.destroy()):K.push(J)})});let Z=f.meta.site.id,$=rp(oG,{}).value;$&&function(e,t,n){let r=()=>{e[t].delete(n)};nW(r),nL(r),nU(()=>{e[t].add(n)}),e[t].add(n)}($,"updateGuards",e=>{var t;let{siteid:n,id:r}=e.params,i=sy.findIndex(e=>e==n);return -1==i?{name:"404"}:(e.meta.site=sg[i],e.meta.id=r,null==(t=c.flv)||t.destroy(),c.flv=void 0,c.qn=0,c.line=0,g.value=void 0,!0)}),rF(()=>f.params,()=>{var e;clearTimeout(s),M(),S(),null==(e=O.value)||e.destory(),Z=f.meta.site.id,J=f.fullPath,N()},void 0),nH(()=>{var e;clearTimeout(t),clearTimeout(r),clearTimeout(n),clearTimeout(s),clearInterval(i),M(),document.title="Lemon live",document.removeEventListener("keydown",q),c.pictureInPicture||null==(e=c.flv)||e.destroy()});let Y=()=>Promise.all(sn(sg,sf)),Q=async e=>{1==e&&await Y()},X=()=>c.showController?j():G(),ee=()=>{c.pictureInPicture=!c.pictureInPicture,document.pictureInPictureElement?document.exitPictureInPicture():p.value.requestPictureInPicture()},et=e=>{let t=e.target.dataset.color;if(!t)return;let n=sE.colors.findIndex(e=>e==t);if(-1==n)return sE.colors.push(t);1!=sE.colors.length&&sE.colors.splice(n,1)};rF(()=>sE.colors,()=>{var e;return null==(e=O.value)?void 0:e.setColors(sE.colors)},void 0),rF(()=>sE.canvasSpeed,()=>{var e;return null==(e=O.value)?void 0:e.setSpeed(sE.canvasSpeed)},void 0),rF(()=>sE.canvasOpacity,()=>{var e;return null==(e=O.value)?void 0:e.setOpacity(sE.canvasOpacity)},void 0),rF(()=>sE.canvasColorOpen,()=>{var e;return null==(e=O.value)?void 0:e.setColors(sE.canvasColorOpen?sE.colors:["#ffffff"])},void 0),rN(()=>{var e,t,n,r;null==(e=O.value)||e.setGap(sE.canvasGap),null==(t=O.value)||t.setFont(sE.canvasFontsize),null==(n=O.value)||n.setRows(sE.canvasRows),null==(r=O.value)||r.resize()}),rF(s_,()=>{G(),clearTimeout(n),c.notice=`当前音量 ${s_.value}%`,p.value.volume=s_.value/100,sA("volume",s_.value),n=setTimeout(()=>c.notice=null,2e3)},void 0),rF(sb,()=>{G(),clearTimeout(n),c.notice=`当前亮度 ${sb.value}%`,h.value.style.filter=100==sb.value?"":`brightness(${sb.value/100})`,sA("brightness",sb.value),n=setTimeout(()=>c.notice=null,2e3)},void 0);let en=tx(),er=e=>{clearTimeout(u),u=setTimeout(()=>{let t=ea("id",e.target,en.value);if(!t)return;let n=ea("site",e.target,en.value);K.push(`/${n}/play/${t}`)},300)},ei=e=>{var t;clearTimeout(u);let n=ea("id",e.target,en.value);if(!n)return;let r=ea("site",e.target,en.value),i=`/${r}/play/${n}`;null==(t=window.open(i,"_blank"))||t.location},ea=(e,t,n)=>{if(t==n)return null;let r=t.dataset[e];return r||ea(e,t.parentElement,n)},es=()=>sb.value=100;rF(()=>c.muted,()=>{G(),clearTimeout(n),c.notice=c.muted?"已静音":"已开启声音",n=setTimeout(()=>c.notice=null,2e3)},void 0);let eo=()=>{if(p.value.muted){p.value.muted=!1,c.muted=!1;return}p.value.muted=!0,c.muted=!0};return(e,t)=>{var n,r,i,a,s,l;return r9(),ii("div",pc,[ic("div",pd,[ic("div",pf,[ic("div",{onClick:t[0]||(t[0]=function(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.$router.back&&e.$router.back(...n)}),class:"i-ri-arrow-left-line hover:text-amber"}),ic("h1",ph,eg(null==(n=tE(g))?void 0:n.title),1),ic("div",{onClick:t[1]||(t[1]=e=>sR.value=!tE(sR)),style:ec(tE(sR)?"transform:rotate(180deg)":"margin-right:1.5rem"),class:"i-ri-arrow-right-s-fill hidden lg:block"},null,4)]),ic("div",{ref_key:"player",ref:h,class:ep(["md:rounded-6px text-4 text-white bg-black cursor-default pos-relative w-full overflow-hidden select-none h-full",{"cursor-none":!tE(c).showController,"text-5":tE(c).fullscreen,"text-5 !pos-fixed left-0 right-0 top-0 bottom-0 z-10 ":tE(c).webscreen}]),onContextmenu:t[19]||(t[19]=aC(()=>{},["prevent"])),onClick:X,onDblclick:z},[ic("div",pp,[ic("video",{playsinline:"","webkit-playsinline":"","x5-video-player-type":"h5",autoplay:"",ref_key:"video",ref:p,class:"w-full h-full pos-absolute",onPlay:H,onPause:W},null,544)]),t5(ic("div",pv,[ic("span",null,eg(tE(c).notice),1)],512),[[at,tE(c).notice]]),ic("canvas",{ref_key:"canvas",ref:A,width:"0",height:"0",class:"w-full h-full z-1 pos-absolute top-0"},null,512),t5(ic("div",{class:ep(["pos-absolute bottom-0 left-0 right-0 px-4 py-2 gap-3 z-20 flex items-center bg-black bg-op-30",{"py-3":tE(c).fullscreen||tE(c).webscreen}]),onClick:t[5]||(t[5]=aC(()=>{},["stop"])),onDblclick:t[6]||(t[6]=aC(()=>{},["stop"]))},[ic("div",{onClick:j,class:ep(["hover:text-amber",tE(c).paused?"i-ri-play-large-fill":"i-ri-pause-large-fill"])},null,2),ic("div",{onClick:F,class:ep(["hover:text-amber",tE(d)?"i-ri-heart-fill":"i-ri-heart-line"])},null,2),ic("div",{onClick:N,class:"i-ri-refresh-line hover:text-amber"}),ic("img",{class:"w-1.5em cursor-pointer",onClick:t[2]||(t[2]=()=>tE(sE).canvasOpen=!tE(sE).canvasOpen),src:tE(sE).canvasOpen?tE(sl):tE(su)},null,8,pm),t[33]||(t[33]=ic("div",{class:"grow"},null,-1)),tE(y).length?(r9(),ii("div",pg,[id(l8,{active:tE(c).qn,"onUpdate:active":t[3]||(t[3]=e=>tE(c).qn=e),list:tE(y)},null,8,["active","list"]),id(l8,{active:tE(c).line,"onUpdate:active":t[4]||(t[4]=e=>tE(c).line=e),list:tE(_)},null,8,["active","list"]),tE(l0)?im("",!0):(r9(),ii("div",{key:0,class:ep(["hover:text-amber ml-2",tE(c).pictureInPicture?"i-ri-picture-in-picture-exit-line":"i-ri-picture-in-picture-2-line"]),onClick:ee},null,2))])):im("",!0),ic("div",{onClick:V,class:"i-mdi-fit-to-screen hover:text-amber"}),ic("div",{onClick:z,class:ep(["hover:text-amber",tE(c).fullscreen?"i-ri-fullscreen-exit-fill":"i-ri-fullscreen-fill"])},null,2)],34),[[at,tE(c).showController]]),tE(l0)?t5((r9(),ii("div",{key:0,class:ep([{"py-3":tE(c).fullscreen||tE(c).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:t[11]||(t[11]=aC(()=>{},["stop"])),onDblclick:t[12]||(t[12]=aC(()=>{},["stop"]))},[ic("div",py,[ic("div",{onClick:t[7]||(t[7]=e=>tE(sx)(!1)),class:"i-ri-sun-line"}),ic("div",null,eg(tE(sb)),1),ic("div",{onClick:t[8]||(t[8]=e=>tE(sx)(!0)),class:"i-ri-sun-fill"})]),t5(ic("div",{class:"flex-1 w-10 truncate text-center"},eg(null==(r=tE(g))?void 0:r.title),513),[[at,tE(c).fullscreen]]),ic("div",p_,[ic("div",{onClick:t[9]||(t[9]=e=>tE(sw)(!1)),class:"i-ri-volume-down-fill"}),ic("div",null,eg(tE(s_)),1),ic("div",{onClick:t[10]||(t[10]=e=>tE(sw)(!0)),class:"i-ri-volume-up-fill"})])],34)),[[at,tE(c).showController]]):t5((r9(),ii("div",pb,[ic("div",{onClick:t[14]||(t[14]=aC(()=>{},["stop"])),onDblclick:t[15]||(t[15]=aC(()=>{},["stop"])),class:"top-50% left-4 flex items-center flex-col pos-absolute z-20",style:{transform:"translateY(-50%)"}},[ic("div",null,eg(tE(sb)),1),id(l2,{value:tE(sb),"onUpdate:value":t[13]||(t[13]=e=>tw(sb)?sb.value=e:null),max:200,min:50},null,8,["value"]),ic("div",{onClick:aC(es,["stop"]),class:"i-ri-sun-line"})],32),ic("div",{onClick:t[17]||(t[17]=aC(()=>{},["stop"])),onDblclick:t[18]||(t[18]=aC(()=>{},["stop"])),class:"top-50% right-4 flex items-center flex-col pos-absolute z-20",style:{transform:"translateY(-50%)"}},[iv(eg(tE(s_))+" ",1),id(l2,{value:tE(s_),"onUpdate:value":t[16]||(t[16]=e=>tw(s_)?s_.value=e:null),max:100,min:0},null,8,["value"]),ic("div",{onClick:aC(eo,["stop"]),class:ep(tE(c).muted?"i-ri-volume-mute-line":"i-ri-volume-down-line")},null,2)],32)],512)),[[at,tE(c).showController]])],34)]),t5(ic("div",pw,[ic("div",px,[ic("img",{src:null==(i=tE(g))?void 0:i.avatar,alt:"",class:"w-8 h-8 rounded-4"},null,8,pk),ic("div",pS,[ic("div",pE,eg(null==(a=tE(g))?void 0:a.nickname),1),ic("div",pT,[ic("img",{class:"w-4 h-4",src:e.$route.meta.site.icon},null,8,pA),iv(" "+eg(e.$route.meta.site.name)+" "+eg(null==(s=tE(g))?void 0:s.category),1)])]),ic("div",null,[t[34]||(t[34]=ic("div",{class:"i-mdi-fire mx-1"},null,-1)),ic("span",null,eg(null==(l=tE(g))?void 0:l.online),1)])]),id(lI,{grow:!0,onTabClick:Q,class:"!h-[calc(100%-3.75rem)]"},{default:t2(()=>[id(lP,{title:"聊天",class:"pos-relative"},{default:t2(()=>{var e;return[ic("div",pO,[ic("img",{onClick:t[20]||(t[20]=()=>tE(sE).sideOpen=!tE(sE).sideOpen),class:"w-1.5em cursor-pointer",src:tE(sE).sideOpen?tE(sl):tE(su)},null,8,pC),ic("div",{onClick:S,class:"i-ri-delete-bin-3-line text-green-5"}),ic("a",{class:"text-green-5",href:null==(e=tE(g))?void 0:e.url,target:"_blank"},t[35]||(t[35]=[ic("div",{class:"i-ri-link"},null,-1)]),8,pI),ic("div",{onClick:U,class:"i-ri-arrow-down-circle-line text-green-5"})]),ic("div",{ref_key:"dm",ref:m,class:"scrolly h-full pl-2 box-border"},null,512)]}),_:1}),id(lP,{title:"关注",class:"box-border px-4"},{default:t2(()=>[ic("div",{onClick:aC(er,["prevent"]),onDblclick:aC(ei,["prevent"])},[(r9(!0),ii(r2,null,n2(tE(w),e=>{var t,n;return r9(),ii("a",{"data-id":e.roomId,"data-site":e.siteId,class:ep([{"text-amber":(null==(t=tE(g))?void 0:t.siteId)==e.siteId&&(null==(n=tE(g))?void 0:n.roomId)==e.roomId},"flex items-center justify-between gap-2 py-2"]),key:`${e.siteId}/${e.roomId}`,href:`/${e.siteId}/play/${e.roomId}`},[ic("div",pR,[ic("img",{class:"w-5 h-5 rounded-5",src:e.avatar,alt:""},null,8,pU),ic("div",null,eg(tE(sm)[e.siteId]),1),ic("div",null,eg(e.nickname),1),ic("div",{class:ep(["inline-block w-3 h-3 rounded-3",[e.status?"bg-amber":"bg-red"]])},null,2),ic("div",null,eg(e.status?"直播中":"未开播"),1)]),ic("div",{class:"i-mdi-heart-off-outline pos-relative w-6 h-6 hover:text-amber",onClick:t=>{t.stopPropagation(),t.preventDefault(),sK(e)}},null,8,pL)],10,pD)}),128))],32)]),_:1}),id(lP,{title:"设置",class:"px-2"},{default:t2(()=>[t[47]||(t[47]=ic("div",{class:"p-3"},"弹幕",-1)),ic("div",pP,[ic("div",pB,[t[36]||(t[36]=ic("div",null,"文字大小",-1)),id(lX,{value:tE(sE).canvasFontsize,"onUpdate:value":t[21]||(t[21]=e=>tE(sE).canvasFontsize=e),max:80,min:8,step:1},null,8,["value"])]),ic("div",pM,[t[37]||(t[37]=ic("div",null,"上下间隔",-1)),id(lX,{value:tE(sE).canvasGap,"onUpdate:value":t[22]||(t[22]=e=>tE(sE).canvasGap=e),max:80,min:1,step:1},null,8,["value"])]),ic("div",pN,[t[38]||(t[38]=ic("div",null,"最大行数",-1)),id(lX,{value:tE(sE).canvasRows,"onUpdate:value":t[23]||(t[23]=e=>tE(sE).canvasRows=e),max:50,min:1,step:1},null,8,["value"])]),ic("div",pF,[t[39]||(t[39]=ic("div",null,"弹幕速度",-1)),id(lX,{value:tE(sE).canvasSpeed,"onUpdate:value":t[24]||(t[24]=e=>tE(sE).canvasSpeed=e),max:32,min:.5,step:.5},null,8,["value"])]),ic("div",pj,[t[40]||(t[40]=ic("div",null,"弹幕透明",-1)),id(lX,{value:tE(sE).canvasOpacity,"onUpdate:value":t[25]||(t[25]=e=>tE(sE).canvasOpacity=e),max:100,min:10,step:10},null,8,["value"])]),ic("div",pz,[t[41]||(t[41]=ic("div",null,"彩色弹幕",-1)),id(lY,{value:tE(sE).canvasColorOpen,"onUpdate:value":t[26]||(t[26]=e=>tE(sE).canvasColorOpen=e)},null,8,["value"])])]),t[48]||(t[48]=ic("div",{class:"p-3"},"聊天",-1)),ic("div",pG,[ic("div",pV,[t[42]||(t[42]=ic("div",null,"文字大小",-1)),id(lX,{value:tE(sE).sideFontsize,"onUpdate:value":t[27]||(t[27]=e=>tE(sE).sideFontsize=e),max:80,min:8,step:1},null,8,["value"])]),ic("div",pH,[t[43]||(t[43]=ic("div",null,"上下间隔",-1)),id(lX,{value:tE(sE).sideGap,"onUpdate:value":t[28]||(t[28]=e=>tE(sE).sideGap=e),max:80,min:0,step:1},null,8,["value"])]),ic("div",pW,[t[44]||(t[44]=ic("div",null,"自动清屏",-1)),id(lX,{value:tE(sE).sideClean,"onUpdate:value":t[29]||(t[29]=e=>tE(sE).sideClean=e),max:500,min:10,step:10},null,8,["value"])]),ic("div",pq,[t[45]||(t[45]=ic("div",null,"彩色消息",-1)),id(lY,{value:tE(sE).sideColorOpen,"onUpdate:value":t[30]||(t[30]=e=>tE(sE).sideColorOpen=e)},null,8,["value"])])]),t[49]||(t[49]=ic("div",{class:"p-3"},"颜色",-1)),ic("div",pK,[(r9(!0),ii(r2,null,n2(tE(sO),e=>(r9(),ii("div",{onClick:et},[ic("div",{class:"w-4 h-4 rounded-2 m-2 shadow cursor-pointer box-border","data-color":e,style:ec(`background:${e};${tE(sE).colors.includes(e)?"box-shadow:0 0 0px 2px white":""}`)},null,12,pJ)]))),256))]),ic("div",pZ,[t[46]||(t[46]=iv("屏蔽 ")),id(lY,{value:tE(sE).blockOpen,"onUpdate:value":t[31]||(t[31]=e=>tE(sE).blockOpen=e)},null,8,["value"])]),t5(ic("textarea",{class:"outline-none w-full text-white b b-solid b-gray-7 p-2 box-border bg-dark shadow rounded-1","onUpdate:modelValue":t[32]||(t[32]=e=>tE(sE).blockWords=e),rows:"5",placeholder:"以空格分隔"},null,512),[[aT,tE(sE).blockWords,void 0,{trim:!0}]])]),_:1})]),_:1})],512),[[at,tE(sR)]])])}}}),pY={class:"w-full box-border mx-auto md:w-80% max-w-2xl text-3 p-4 pos-relative"},pQ={class:"flex gap-4 justify-between items-center p-4 md:p-6 b-1px b-solid b-gray-7 rounded-2"},pX={class:"py-2 text-4"},p0={class:"flex gap-2 text-3"},p1={class:"p-4 md:p-6 b-1px b-solid b-gray-7 rounded-2 my-4"},p2={class:"text-center text-4"},p5={class:"pos-relative w-full mt-6"},p3={class:"pos-relative w-full mt-4 mb-6"},p6={class:"pos-relative w-full mt-4 mb-6"},p4={class:"p-4 md:p-6 b-1px b-solid b-gray-7 rounded-2 my-4"},p8=["onClick"],p9={class:"p-6 b-1px b-solid b-gray-7 rounded-2 my-4"},p7={class:"my-5 line-height-loose"},ve={class:"text-rose mx-2"},vt={class:"text-rose mx-2"},vn={class:"flex justify-evenly"},vr=ny({__name:"user",setup(e){let t=tx("hide"),n=tc({username:"",password:"",newpassword:""}),r=tx(),i=/^[\u4e00-\u9fa5a-zA-Z0-9]{1,12}$/,a=/^.{0,15}$/,s=async()=>{if("hide"!=t.value){if(!i.test(n.username))return sh.warning("账号1到12个字符!");if(!a.test(n.password))return sh.warning("密码0到15个字符!");"sign"==t.value?await sN(n):await sj(n),l()}},l=()=>{n.username="",n.newpassword="",n.password="",t.value="hide"},u=()=>{t.value="hide",n.password="",n.username=""},c=()=>{l(),r.value=null,sF(sB.token)},d=()=>{null!=r.value&&sF(r.value.token).finally(()=>r.value=null)},f=e=>{navigator.clipboard.writeText(e.target.innerText).then(()=>sh.success("已复制到剪贴板")).catch(()=>sh.warning("复制到剪贴板失败"))},h=["https://lemonlive.deno.dev","https://lemonlive.pages.dev","https://lemonlive25.deno.dev","https://lemonlive25.pages.dev"];return(e,i)=>{var a,l;return r9(),ii("div",pY,[ic("div",pQ,[ic("div",pX,eg(tE(sB).user.username||"未登录"),1),ic("div",p0,[t5(ic("div",{onClick:i[0]||(i[0]=e=>t.value="sign"),class:"cursor-pointer text-black bg-green hover:bg-green-7 py-2 px-2 md:px-4 rounded-6"},"登录 / 注册",512),[[at,"hide"==tE(t)&&!tE(sM)]]),t5(ic("div",{onClick:i[1]||(i[1]=e=>t.value="reset"),class:"cursor-pointer text-black bg-green hover:bg-green-7 py-2 px-2 md:px-4 rounded-6"}," 修改密码 ",512),[[at,"hide"==tE(t)&&tE(sM)]]),t5(ic("div",{onClick:c,class:"cursor-pointer text-black bg-green hover:bg-green-7 py-2 px-2 md:px-4 rounded-6"},"退出登录",512),[[at,tE(sM)]]),t5(ic("div",{onClick:i[2]||(i[2]=()=>tE(sH)(!0)),class:"cursor-pointer text-black bg-green hover:bg-green-7 py-2 px-2 md:px-4 rounded-6"},"立即同步",512),[[at,tE(sM)]])])]),id(iY,null,{default:t2(()=>[t5(ic("div",p1,[ic("div",p2,eg("sign"==tE(t)?"登录 / 注册":"修改密码"),1),ic("div",p5,[t5(ic("input",{class:"md:text-4 box-border w-full py-3 px-12 focus:b-green text-white bg-transparent b-1 b-style-groove b-gray-7 rounded-6 outline-none",type:"text","onUpdate:modelValue":i[3]||(i[3]=e=>tE(n).username=e),placeholder:"请输入账号"},null,512),[[aT,tE(n).username,void 0,{trim:!0}]]),i[9]||(i[9]=ic("div",{class:"i-ri-user-smile-line pos-absolute left-4 top-2 bg-gray"},null,-1))]),ic("div",p3,[t5(ic("input",{class:"md:text-4 box-border w-full py-3 px-12 text-white bg-transparent b-1 b-style-groove focus:b-green b-gray-7 rounded-6 outline-none",type:"text","onUpdate:modelValue":i[4]||(i[4]=e=>tE(n).password=e),placeholder:"请输入密码"},null,512),[[aT,tE(n).password,void 0,{trim:!0}]]),i[10]||(i[10]=ic("div",{class:"i-ri-lock-password-line pos-absolute left-4 top-2 bg-gray"},null,-1))]),t5(ic("div",p6,[t5(ic("input",{class:"md:text-4 box-border w-full py-3 px-12 text-white bg-transparent b-1 b-style-groove focus:b-green b-gray-7 rounded-6 outline-none",type:"text","onUpdate:modelValue":i[5]||(i[5]=e=>tE(n).newpassword=e),placeholder:"请输入新密码"},null,512),[[aT,tE(n).newpassword,void 0,{trim:!0}]]),i[11]||(i[11]=ic("div",{class:"i-ri-lock-password-line pos-absolute left-4 top-2 bg-gray"},null,-1))],512),[[at,"reset"==tE(t)]]),ic("div",{class:"flex w-full justify-evenly"},[ic("div",{onClick:u,class:"cursor-pointer flex gap-2 text-black bg-gray-5 hover:bg-gray-7 py-3 px-8 rounded-6"},"取消"),ic("div",{onClick:s,class:"cursor-pointer flex gap-2 text-black bg-green-5 hover:bg-green-7 py-3 px-8 rounded-6"},"确定")])],512),[[at,"hide"!=tE(t)]])]),_:1}),id(iY,null,{default:t2(()=>[t5(ic("div",p4,[i[12]||(i[12]=ic("div",{class:"text-3 md:text-4 mb-3"},"登录设备",-1)),(r9(!0),ii(r2,null,n2(tE(sB).user.token,e=>(r9(),ii("div",{onClick:t=>r.value=e,class:ep([{"c-green":e.token==tE(sB).token},"flex cursor-pointer py-3 my-3 rounded-6 hover:op-80 gap-3 justify-between items-center"])},[ic("div",null,eg(e.agent),1),ic("div",null,eg(e.domain),1),ic("div",null,eg(e.time),1)],10,p8))),256))],512),[[at,tE(sM)||!0]])]),_:1}),i[17]||(i[17]=function(e,t){let n=id(r6,null,e);return n.staticCount=1,n}('<div class="p-4 md:p-6 b-1px b-solid b-gray-7 rounded-2 my-4"><div class="text-3 md:text-4 mb-3">支持</div><div class=""><img class="h-40 md:h-50 mr-3" src="https://i0.hdslb.com/bfs/article/828b4686d0bcd7a427939b1f121f322898845873.png"><img class="h-40 md:h-50 mt-2" src="https://i0.hdslb.com/bfs/article/d07b5e8cbae76f0fc38a8049c433d3d598845873.jpg"></div></div>',0)),ic("div",p9,[i[13]||(i[13]=ic("div",{class:"text-4 mb"},"域名",-1)),(r9(),ii(r2,null,n2(h,e=>ic("div",{class:"text-4 my-2 py-2 cursor-pointer hover:c-green",onClick:f},eg(e),1)),64))]),(r9(),ia(nn,{to:"body"},[t5(ic("div",{class:ep(["pos-absolute left-0 top-0 right-0 bottom-0 flex justify-center items-center",{"md:ml-17.5":tE(sU)}]),onClick:i[8]||(i[8]=e=>r.value=null)},[ic("div",{class:"p-4 py-6 md:p-6 max-w-80% box-border bg-gray-7 rounded-2 text-3",onClick:i[7]||(i[7]=aC(()=>{},["stop"]))},[i[16]||(i[16]=ic("div",{class:"text-4"},"退出登录",-1)),ic("div",p7,[i[14]||(i[14]=iv(" 确定要登出 ")),ic("span",ve,eg(null==(a=tE(r))?void 0:a.domain),1),ic("span",vt,eg(null==(l=tE(r))?void 0:l.agent),1),i[15]||(i[15]=iv(" 吗? "))]),ic("div",vn,[ic("div",{onClick:i[6]||(i[6]=e=>r.value=null),class:"cursor-pointer text-black bg-gray-4 hover:op-50 py-2 px-5 rounded-6"},"取消 "),ic("div",{onClick:d,class:"cursor-pointer text-black bg-green hover:op-50 py-2 px-5 rounded-6"},"确定")])])],2),[[at,tE(r)]])]))])}}}),vi={"h-full":"",flex:"","justify-center":"","items-center":""},va=(0,aJ.default)({},[["render",function(e,t){return r9(),ii("div",vi,t[0]||(t[0]=[ic("div",{"text-center":"","text-8":"","line-height-8":""},[ic("div",{"font-900":""},"404"),ic("div",{"mt-4":""},"页面未找到")],-1)]))}]]);async function vs(e){let{siteid:t,id:n}=e.params,r=sg.findIndex(e=>e.id==t);return -1==r?{name:"404"}:(e.meta.site=sg[r],e.meta.id=n,e.meta.index=r,sD.value=r,!0)}let vo=function(e){let t,n,r,i=function(e,t){let n=[],r=new Map;function i(e,s,l){let u,c,d=!l,f=oB(e);f.aliasOf=l&&l.record;let h=oN(t,e),p=[f];if("alias"in e)for(let t of"string"==typeof e.alias?[e.alias]:e.alias)p.push(oB(s$({},f,{components:l?l.record.components:f.components,path:t,aliasOf:l?l.record:f})));for(let t of p){let{path:p}=t;if(s&&"/"!==p[0]){let e=s.record.path,n="/"===e[e.length-1]?"":"/";t.path=s.record.path+(p&&n+p)}if(u=function(e,t,n){let r=function(e,t){let n=s$({},oC,t),r=[],i=n.start?"^":"",a=[];for(let t of e){let e=t.length?[]:[90];n.strict&&!t.length&&(i+="/");for(let r=0;r<t.length;r++){let s=t[r],l=40+.25*!!n.sensitive;if(0===s.type)r||(i+="/"),i+=s.value.replace(oI,"\\$&"),l+=40;else if(1===s.type){let{value:e,repeatable:n,optional:u,regexp:c}=s;a.push({name:e,repeatable:n,optional:u});let d=c||oO;if(d!==oO){l+=10;try{RegExp(`(${d})`)}catch(t){throw Error(`Invalid custom RegExp for param "${e}" (${d}): `+t.message)}}let f=n?`((?:${d})(?:/(?:${d}))*)`:`(${d})`;r||(f=u&&t.length<2?`(?:/${f})`:"/"+f),u&&(f+="?"),i+=f,l+=20,u&&(l+=-8),n&&(l+=-20),".*"===d&&(l+=-50)}e.push(l)}r.push(e)}if(n.strict&&n.end){let e=r.length-1;r[e][r[e].length-1]+=.7000000000000001}n.strict||(i+="/?"),n.end?i+="$":n.strict&&!i.endsWith("/")&&(i+="(?:/|$)");let s=new RegExp(i,n.sensitive?"":"i");return{re:s,score:r,keys:a,parse:function(e){let t=e.match(s),n={};if(!t)return null;for(let e=1;e<t.length;e++){let r=t[e]||"",i=a[e-1];n[i.name]=r&&i.repeatable?r.split("/"):r}return n},stringify:function(t){let n="",r=!1;for(let i of e)for(let e of(r&&n.endsWith("/")||(n+="/"),r=!1,i))if(0===e.type)n+=e.value;else if(1===e.type){let{value:a,repeatable:s,optional:l}=e,u=a in t?t[a]:"";if(sX(u)&&!s)throw Error(`Provided param "${a}" is an array but it is not repeatable (* or + modifiers)`);let c=sX(u)?u.join("/"):u;if(!c)if(l)i.length<2&&(n.endsWith("/")?n=n.slice(0,-1):r=!0);else throw Error(`Missing required param "${a}"`);n+=c}return n||"/"}}}(function(e){let t,n;if(!e)return[[]];if("/"===e)return[[oU]];if(!e.startsWith("/"))throw Error(`Invalid path "${e}"`);function r(e){throw Error(`ERR (${i})/"${c}": ${e}`)}let i=0,a=0,s=[];function l(){t&&s.push(t),t=[]}let u=0,c="",d="";function f(){c&&(0===i?t.push({type:0,value:c}):1===i||2===i||3===i?(t.length>1&&("*"===n||"+"===n)&&r(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),t.push({type:1,value:c,regexp:d,repeatable:"*"===n||"+"===n,optional:"*"===n||"?"===n})):r("Invalid state to consume buffer"),c="")}for(;u<e.length;){if("\\"===(n=e[u++])&&2!==i){a=i,i=4;continue}switch(i){case 0:"/"===n?(c&&f(),l()):":"===n?(f(),i=1):c+=n;break;case 4:c+=n,i=a;break;case 1:"("===n?i=2:oL.test(n)?c+=n:(f(),i=0,"*"!==n&&"?"!==n&&"+"!==n&&u--);break;case 2:")"===n?"\\"==d[d.length-1]?d=d.slice(0,-1)+n:i=3:d+=n;break;case 3:f(),i=0,"*"!==n&&"?"!==n&&"+"!==n&&u--,d="";break;default:r("Unknown state")}}return 2===i&&r(`Unfinished custom RegExp for param "${c}"`),f(),l(),s}(e.path),n),i=s$(r,{record:e,parent:t,children:[],alias:[]});return t&&!i.record.aliasOf==!t.record.aliasOf&&t.children.push(i),i}(t,s,h),l?l.alias.push(u):((c=c||u)!==u&&c.alias.push(u),d&&e.name&&!oM(u)&&a(e.name)),oF(u)&&function(e){let t=function(e,t){let n=0,r=t.length;for(;n!==r;){let i=n+r>>1;0>oD(e,t[i])?r=i:n=i+1}let i=function(e){let t=e;for(;t=t.parent;)if(oF(t)&&0===oD(e,t))return t}(e);return i&&(r=t.lastIndexOf(i,r-1)),r}(e,n);n.splice(t,0,e),e.record.name&&!oM(e)&&r.set(e.record.name,e)}(u),f.children){let e=f.children;for(let t=0;t<e.length;t++)i(e[t],u,l&&l.children[t])}l=l||u}return c?()=>{a(c)}:sQ}function a(e){if(oS(e)){let t=r.get(e);t&&(r.delete(e),n.splice(n.indexOf(t),1),t.children.forEach(a),t.alias.forEach(a))}else{let t=n.indexOf(e);t>-1&&(n.splice(t,1),e.record.name&&r.delete(e.record.name),e.children.forEach(a),e.alias.forEach(a))}}return t=oN({strict:!1,end:!0,sensitive:!1},t),e.forEach(e=>i(e)),{addRoute:i,resolve:function(e,t){let i,a,s,l={};if("name"in e&&e.name){if(!(i=r.get(e.name)))throw oT(1,{location:e});s=i.record.name,l=s$(oP(t.params,i.keys.filter(e=>!e.optional).concat(i.parent?i.parent.keys.filter(e=>e.optional):[]).map(e=>e.name)),e.params&&oP(e.params,i.keys.map(e=>e.name))),a=i.stringify(l)}else if(null!=e.path)a=e.path,(i=n.find(e=>e.re.test(a)))&&(l=i.parse(a),s=i.record.name);else{if(!(i=t.name?r.get(t.name):n.find(e=>e.re.test(t.path))))throw oT(1,{location:e,currentLocation:t});s=i.record.name,l=s$({},t.params,e.params),a=i.stringify(l)}let u=[],c=i;for(;c;)u.unshift(c.record),c=c.parent;return{name:s,path:a,params:l,matched:u,meta:u.reduce((e,t)=>s$(e,t.meta),{})}},removeRoute:a,clearRoutes:function(){n.length=0,r.clear()},getRoutes:function(){return n},getRecordMatcher:function(e){return r.get(e)}}}(e.routes,e),a=e.parseQuery||oj,s=e.stringifyQuery||oz,l=e.history,u=oK(),c=oK(),d=oK(),f=tk(ov,!0),h=ov;sJ&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");let p=sY.bind(null,e=>""+e),m=sY.bind(null,os),g=sY.bind(null,oo);function y(e,t){let n;if(t=s$({},t||f.value),"string"==typeof e){let n=oc(a,e,t.path),r=i.resolve({path:n.path},t),s=l.createHref(n.fullPath);return s$(n,r,{params:g(r.params),hash:oo(n.hash),redirectedFrom:void 0,href:s})}if(null!=e.path)n=s$({},e,{path:oc(a,e.path,t.path).path});else{let r=s$({},e.params);for(let e in r)null==r[e]&&delete r[e];n=s$({},e,{params:m(r)}),t.params=m(t.params)}let r=i.resolve(n,t),u=e.hash||"";r.params=p(g(r.params));let c=function(e,t){let n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}(s,s$({},e,{hash:oi(u).replace(oe,"{").replace(on,"}").replace(s9,"^"),path:r.path})),d=l.createHref(c);return s$({fullPath:c,hash:u,query:s===oz?function(e){let t={};for(let n in e){let r=e[n];void 0!==r&&(t[n]=sX(r)?r.map(e=>null==e?null:""+e):null==r?r:""+r)}return t}(e.query):e.query||{}},r,{redirectedFrom:void 0,href:d})}function _(e){return"string"==typeof e?oc(a,e,f.value.path):s$({},e)}function b(e,t){if(h!==e)return oT(8,{from:t,to:e})}function w(e){let t=e.matched[e.matched.length-1];if(t&&t.redirect){let{redirect:n}=t,r="function"==typeof n?n(e):n;return"string"==typeof r&&((r=r.includes("?")||r.includes("#")?r=_(r):{path:r}).params={}),s$({query:e.query,hash:e.hash,params:null!=r.path?{}:e.params},r)}}function x(e,t){let n,r=h=y(e),i=f.value,a=e.state,l=e.force,u=!0===e.replace,c=w(r);return c?x(s$(_(c),{state:"object"==typeof c?s$({},a,c.state):a,force:l,replace:u}),t||r):(r.redirectedFrom=t,!l&&function(e,t,n){let r=t.matched.length-1,i=n.matched.length-1;return r>-1&&r===i&&of(t.matched[r],n.matched[i])&&oh(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}(s,i,r)&&(n=oT(16,{to:r,from:i}),R(i,i,!0,!1)),(n?Promise.resolve(n):E(r,i)).catch(e=>oA(e)?oA(e,2)?e:D(e):I(e,r,i)).then(e=>{if(e){if(oA(e,2))return x(s$({replace:u},_(e.to),{state:"object"==typeof e.to?s$({},a,e.to.state):a,force:l}),t||r)}else e=A(r,i,!0,u,a);return T(r,i,e),e}))}function k(e,t){let n=b(e,t);return n?Promise.reject(n):Promise.resolve()}function S(e){let t=L.values().next().value;return t&&"function"==typeof t.runWithContext?t.runWithContext(e):e()}function E(e,t){let n,[r,i,a]=function(e,t){let n=[],r=[],i=[],a=Math.max(t.matched.length,e.matched.length);for(let s=0;s<a;s++){let a=t.matched[s];a&&(e.matched.find(e=>of(e,a))?r.push(a):n.push(a));let l=e.matched[s];l&&!t.matched.find(e=>of(e,l))&&i.push(l)}return[n,r,i]}(e,t);for(let i of(n=oZ(r.reverse(),"beforeRouteLeave",e,t),r))i.leaveGuards.forEach(r=>{n.push(oJ(r,e,t))});let s=k.bind(null,e,t);return n.push(s),B(n).then(()=>{for(let r of(n=[],u.list()))n.push(oJ(r,e,t));return n.push(s),B(n)}).then(()=>{for(let r of(n=oZ(i,"beforeRouteUpdate",e,t),i))r.updateGuards.forEach(r=>{n.push(oJ(r,e,t))});return n.push(s),B(n)}).then(()=>{for(let r of(n=[],a))if(r.beforeEnter)if(sX(r.beforeEnter))for(let i of r.beforeEnter)n.push(oJ(i,e,t));else n.push(oJ(r.beforeEnter,e,t));return n.push(s),B(n)}).then(()=>(e.matched.forEach(e=>e.enterCallbacks={}),(n=oZ(a,"beforeRouteEnter",e,t,S)).push(s),B(n))).then(()=>{for(let r of(n=[],c.list()))n.push(oJ(r,e,t));return n.push(s),B(n)}).catch(e=>oA(e,8)?e:Promise.reject(e))}function T(e,t,n){d.list().forEach(r=>S(()=>r(e,t,n)))}function A(e,t,n,r,i){let a=b(e,t);if(a)return a;let s=t===ov,u=sJ?history.state:{};n&&(r||s?l.replace(e.fullPath,s$({scroll:s&&u&&u.scroll},i)):l.push(e.fullPath,i)),f.value=e,R(e,t,n,s),D()}let O=oK(),C=oK();function I(e,t,n){D(e);let r=C.list();return r.length?r.forEach(r=>r(e,t,n)):console.error(e),Promise.reject(e)}function D(e){return n||(n=!e,t||(t=l.listen((e,t,n)=>{var r,i;if(!P.listening)return;let a=y(e),s=w(a);if(s)return void x(s$(s,{replace:!0,force:!0}),a).catch(sQ);h=a;let u=f.value;sJ&&(r=o_(u.fullPath,n.delta),i=oy(),ob.set(r,i)),E(a,u).catch(e=>oA(e,12)?e:oA(e,2)?(x(s$(_(e.to),{force:!0}),a).then(e=>{oA(e,20)&&!n.delta&&n.type===aB.pop&&l.go(-1,!1)}).catch(sQ),Promise.reject()):(n.delta&&l.go(-n.delta,!1),I(e,a,u))).then(e=>{(e=e||A(a,u,!1))&&(n.delta&&!oA(e,8)?l.go(-n.delta,!1):n.type===aB.pop&&oA(e,20)&&l.go(-1,!1)),T(a,u,e)}).catch(sQ)})),O.list().forEach(([t,n])=>e?n(e):t()),O.reset()),e}function R(t,n,r,i){let{scrollBehavior:a}=e;if(!sJ||!a)return Promise.resolve();let s=!r&&function(e){let t=ob.get(e);return ob.delete(e),t}(o_(t.fullPath,0))||(i||!r)&&history.state&&history.state.scroll||null;return tW().then(()=>a(t,n,s)).then(e=>e&&function(e){let t;if("el"in e){let n=e.el,r="string"==typeof n&&n.startsWith("#"),i="string"==typeof n?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!i)return;t=function(e,t){let n=document.documentElement.getBoundingClientRect(),r=e.getBoundingClientRect();return{behavior:t.behavior,left:r.left-n.left-(t.left||0),top:r.top-n.top-(t.top||0)}}(i,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(null!=t.left?t.left:window.scrollX,null!=t.top?t.top:window.scrollY)}(e)).catch(e=>I(e,t,n))}let U=e=>l.go(e),L=new Set,P={currentRoute:f,listening:!0,addRoute:function(e,t){let n,r;return oS(e)?(n=i.getRecordMatcher(e),r=t):r=e,i.addRoute(r,n)},removeRoute:function(e){let t=i.getRecordMatcher(e);t&&i.removeRoute(t)},clearRoutes:i.clearRoutes,hasRoute:function(e){return!!i.getRecordMatcher(e)},getRoutes:function(){return i.getRoutes().map(e=>e.record)},resolve:y,options:e,push:function(e){return x(e)},replace:function(e){return x(s$(_(e),{replace:!0}))},go:U,back:()=>U(-1),forward:()=>U(1),beforeEach:u.add,beforeResolve:c.add,afterEach:d.add,onError:C.add,isReady:function(){return n&&f.value!==ov?Promise.resolve():new Promise((e,t)=>{O.add([e,t])})},install(e){e.component("RouterLink",oY),e.component("RouterView",o0),e.config.globalProperties.$router=this,Object.defineProperty(e.config.globalProperties,"$route",{enumerable:!0,get:()=>tE(f)}),sJ&&!r&&f.value===ov&&(r=!0,x(l.location).catch(e=>{}));let i={};for(let e in ov)Object.defineProperty(i,e,{get:()=>f.value[e],enumerable:!0});e.provide(oH,this),e.provide(oW,td(i)),e.provide(oq,f);let a=e.unmount;L.add(e),e.unmount=function(){L.delete(e),L.size<1&&(h=ov,t&&t(),t=null,f.value=ov,r=!1,n=!1),a()}}};function B(e){return e.reduce((e,t)=>e.then(()=>S(t)),Promise.resolve())}return P}({history:function(e){let t=function(e){let{history:t,location:n}=window,r={value:ox(e,n)},i={value:t.state};function a(r,a,s){let l=e.indexOf("#"),u=l>-1?(n.host&&document.querySelector("base")?e:e.slice(l))+r:ow()+e+r;try{t[s?"replaceState":"pushState"](a,"",u),i.value=a}catch(e){console.error(e),n[s?"replace":"assign"](u)}}return i.value||a(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0),{location:r,state:i,push:function(e,n){let s=s$({},i.value,t.state,{forward:e,scroll:oy()});a(s.current,s,!0);let l=s$({},ok(r.value,e,null),{position:s.position+1},n);a(e,l,!1),r.value=e},replace:function(e,n){let s=s$({},t.state,ok(i.value.back,e,i.value.forward,!0),n,{position:i.value.position});a(e,s,!0),r.value=e}}}(e=function(e){if(!e)if(sJ){let t=document.querySelector("base");e=(e=t&&t.getAttribute("href")||"/").replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return"/"!==e[0]&&"#"!==e[0]&&(e="/"+e),ou(e)}(e)),n=function(e,t,n,r){let i=[],a=[],s=null,l=({state:a})=>{let l=ox(e,location),u=n.value,c=t.value,d=0;if(a){if(n.value=l,t.value=a,s&&s===u){s=null;return}d=c?a.position-c.position:0}else r(l);i.forEach(e=>{e(n.value,u,{delta:d,type:aB.pop,direction:d?d>0?aM.forward:aM.back:aM.unknown})})};function u(){let{history:e}=window;e.state&&e.replaceState(s$({},e.state,{scroll:oy()}),"")}return window.addEventListener("popstate",l),window.addEventListener("beforeunload",u,{passive:!0}),{pauseListeners:function(){s=n.value},listen:function(e){i.push(e);let t=()=>{let t=i.indexOf(e);t>-1&&i.splice(t,1)};return a.push(t),t},destroy:function(){for(let e of a)e();a=[],window.removeEventListener("popstate",l),window.removeEventListener("beforeunload",u)}}}(e,t.state,t.location,t.replace),r=s$({location:"",base:e,go:function(e,t=!0){t||n.pauseListeners(),history.go(e)},createHref:og.bind(null,e)},t,n);return Object.defineProperty(r,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(r,"state",{enumerable:!0,get:()=>t.state.value}),r}(),routes:[{path:"/",redirect:()=>`/${sy[sD.value]}`},{path:"/follow",component:lZ},{path:"/user",component:vr},{path:"/category",redirect:()=>`/${sy[sD.value]}/category`},{path:"/search",redirect:()=>`/${sy[sD.value]}/search`},{path:"/:siteid",component:l$,beforeEnter:vs},{path:"/:siteid/category",component:lj,beforeEnter:vs},{path:"/:siteid/category/:id",component:lx,beforeEnter:vs},{path:"/:siteid/play/:id",component:p$,beforeEnter:vs},{path:"/:siteid/search",component:lq,beforeEnter:vs},{path:"/:pathMatch(.*)*",name:"404",component:va}]});var vl=n(632);n.n(vl)()();let vu=aP(o8);vu.use(vo),vu.mount("#app")})()})();
|