@lzwme/m3u8-dl 1.5.0 → 1.6.0-0
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/README.MD +361 -68
- package/cjs/cli.js +37 -24
- package/cjs/i18n/locales/en.d.ts +108 -0
- package/cjs/i18n/locales/en.js +109 -0
- package/cjs/i18n/locales/zh.d.ts +108 -0
- package/cjs/i18n/locales/zh.js +109 -0
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/lib/file-download.js +8 -5
- package/cjs/lib/getM3u8Urls.d.ts +6 -0
- package/cjs/lib/getM3u8Urls.js +45 -27
- package/cjs/lib/i18n.d.ts +27 -0
- package/cjs/lib/i18n.js +89 -0
- package/cjs/lib/m3u8-convert.js +2 -7
- package/cjs/lib/m3u8-download.js +36 -15
- package/cjs/lib/utils.js +4 -4
- package/cjs/server/download-server.d.ts +1 -0
- package/cjs/server/download-server.js +111 -39
- package/cjs/types/index.d.ts +1 -1
- package/cjs/types/index.js +1 -1
- package/cjs/types/m3u8.d.ts +4 -2
- package/client/assets/main-DYJAIw1q.css +1 -0
- package/client/assets/main-XL0wiaDU.js +25 -0
- package/client/index.html +4 -1144
- package/client/play.html +221 -14
- package/package.json +20 -17
- package/client/style.css +0 -137
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))s(l);new MutationObserver(l=>{for(const o of l)if(o.type==="childList")for(const r of o.addedNodes)r.tagName==="LINK"&&r.rel==="modulepreload"&&s(r)}).observe(document,{childList:!0,subtree:!0});function n(l){const o={};return l.integrity&&(o.integrity=l.integrity),l.referrerPolicy&&(o.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?o.credentials="include":l.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function s(l){if(l.ep)return;l.ep=!0;const o=n(l);fetch(l.href,o)}})();function $l(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const $e={},Kn=[],Rt=()=>{},Ja=()=>!1,fo=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Nl=e=>e.startsWith("onUpdate:"),qe=Object.assign,Il=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},hu=Object.prototype.hasOwnProperty,Ce=(e,t)=>hu.call(e,t),re=Array.isArray,Yn=e=>Ps(e)==="[object Map]",ns=e=>Ps(e)==="[object Set]",fr=e=>Ps(e)==="[object Date]",ue=e=>typeof e=="function",We=e=>typeof e=="string",Lt=e=>typeof e=="symbol",Le=e=>e!==null&&typeof e=="object",Za=e=>(Le(e)||ue(e))&&ue(e.then)&&ue(e.catch),ei=Object.prototype.toString,Ps=e=>ei.call(e),gu=e=>Ps(e).slice(8,-1),ti=e=>Ps(e)==="[object Object]",Pl=e=>We(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,us=$l(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),mo=e=>{const t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},vu=/-\w/g,Et=mo(e=>e.replace(vu,t=>t.slice(1).toUpperCase())),bu=/\B([A-Z])/g,bn=mo(e=>e.replace(bu,"-$1").toLowerCase()),po=mo(e=>e.charAt(0).toUpperCase()+e.slice(1)),Oo=mo(e=>e?`on${po(e)}`:""),fn=(e,t)=>!Object.is(e,t),qs=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},ni=(e,t,n,s=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:s,value:n})},ho=e=>{const t=parseFloat(e);return isNaN(t)?e:t},_u=e=>{const t=We(e)?Number(e):NaN;return isNaN(t)?e:t};let dr;const go=()=>dr||(dr=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function vo(e){if(re(e)){const t={};for(let n=0;n<e.length;n++){const s=e[n],l=We(s)?Eu(s):vo(s);if(l)for(const o in l)t[o]=l[o]}return t}else if(We(e)||Le(e))return e}const yu=/;(?![^(]*\))/g,wu=/:([^]+)/,xu=/\/\*[^]*?\*\//g;function Eu(e){const t={};return e.replace(xu,"").split(yu).forEach(n=>{if(n){const s=n.split(wu);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function Qe(e){let t="";if(We(e))t=e;else if(re(e))for(let n=0;n<e.length;n++){const s=Qe(e[n]);s&&(t+=s+" ")}else if(Le(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const ku="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",Cu=$l(ku);function si(e){return!!e||e===""}function Su(e,t){if(e.length!==t.length)return!1;let n=!0;for(let s=0;n&&s<e.length;s++)n=As(e[s],t[s]);return n}function As(e,t){if(e===t)return!0;let n=fr(e),s=fr(t);if(n||s)return n&&s?e.getTime()===t.getTime():!1;if(n=Lt(e),s=Lt(t),n||s)return e===t;if(n=re(e),s=re(t),n||s)return n&&s?Su(e,t):!1;if(n=Le(e),s=Le(t),n||s){if(!n||!s)return!1;const l=Object.keys(e).length,o=Object.keys(t).length;if(l!==o)return!1;for(const r in e){const a=e.hasOwnProperty(r),i=t.hasOwnProperty(r);if(a&&!i||!a&&i||!As(e[r],t[r]))return!1}}return String(e)===String(t)}function Al(e,t){return e.findIndex(n=>As(n,t))}const oi=e=>!!(e&&e.__v_isRef===!0),E=e=>We(e)?e:e==null?"":re(e)||Le(e)&&(e.toString===ei||!ue(e.toString))?oi(e)?E(e.value):JSON.stringify(e,li,2):String(e),li=(e,t)=>oi(t)?li(e,t.value):Yn(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,l],o)=>(n[Ro(s,o)+" =>"]=l,n),{})}:ns(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Ro(n))}:Lt(t)?Ro(t):Le(t)&&!re(t)&&!ti(t)?String(t):t,Ro=(e,t="")=>{var n;return Lt(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};let nt;class ri{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=nt,!t&&nt&&(this.index=(nt.scopes||(nt.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].pause();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].resume();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].resume()}}run(t){if(this._active){const n=nt;try{return nt=this,t()}finally{nt=n}}}on(){++this._on===1&&(this.prevScope=nt,nt=this)}off(){this._on>0&&--this._on===0&&(nt=this.prevScope,this.prevScope=void 0)}stop(t){if(this._active){this._active=!1;let n,s;for(n=0,s=this.effects.length;n<s;n++)this.effects[n].stop();for(this.effects.length=0,n=0,s=this.cleanups.length;n<s;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){for(n=0,s=this.scopes.length;n<s;n++)this.scopes[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const l=this.parent.scopes.pop();l&&l!==this&&(this.parent.scopes[this.index]=l,l.index=this.index)}this.parent=void 0}}}function Dl(e){return new ri(e)}function ai(){return nt}function Tu(e,t=!1){nt&&nt.cleanups.push(e)}let Ne;const Mo=new WeakSet;class ii{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,nt&&nt.active&&nt.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Mo.has(this)&&(Mo.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||ui(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,mr(this),fi(this);const t=Ne,n=Tt;Ne=this,Tt=!0;try{return this.fn()}finally{di(this),Ne=t,Tt=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)Ml(t);this.deps=this.depsTail=void 0,mr(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Mo.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){tl(this)&&this.run()}get dirty(){return tl(this)}}let ci=0,fs,ds;function ui(e,t=!1){if(e.flags|=8,t){e.next=ds,ds=e;return}e.next=fs,fs=e}function Ol(){ci++}function Rl(){if(--ci>0)return;if(ds){let t=ds;for(ds=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;fs;){let t=fs;for(fs=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(s){e||(e=s)}t=n}}if(e)throw e}function fi(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function di(e){let t,n=e.depsTail,s=n;for(;s;){const l=s.prevDep;s.version===-1?(s===n&&(n=l),Ml(s),Lu(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=l}e.deps=t,e.depsTail=n}function tl(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(mi(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function mi(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===_s)||(e.globalVersion=_s,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!tl(e))))return;e.flags|=2;const t=e.dep,n=Ne,s=Tt;Ne=e,Tt=!0;try{fi(e);const l=e.fn(e._value);(t.version===0||fn(l,e._value))&&(e.flags|=128,e._value=l,t.version++)}catch(l){throw t.version++,l}finally{Ne=n,Tt=s,di(e),e.flags&=-3}}function Ml(e,t=!1){const{dep:n,prevSub:s,nextSub:l}=e;if(s&&(s.nextSub=l,e.prevSub=void 0),l&&(l.prevSub=s,e.nextSub=void 0),n.subs===e&&(n.subs=s,!s&&n.computed)){n.computed.flags&=-5;for(let o=n.computed.deps;o;o=o.nextDep)Ml(o,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Lu(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Tt=!0;const pi=[];function Zt(){pi.push(Tt),Tt=!1}function en(){const e=pi.pop();Tt=e===void 0?!0:e}function mr(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=Ne;Ne=void 0;try{t()}finally{Ne=n}}}let _s=0;class $u{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Fl{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!Ne||!Tt||Ne===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==Ne)n=this.activeLink=new $u(Ne,this),Ne.deps?(n.prevDep=Ne.depsTail,Ne.depsTail.nextDep=n,Ne.depsTail=n):Ne.deps=Ne.depsTail=n,hi(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const s=n.nextDep;s.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=s),n.prevDep=Ne.depsTail,n.nextDep=void 0,Ne.depsTail.nextDep=n,Ne.depsTail=n,Ne.deps===n&&(Ne.deps=s)}return n}trigger(t){this.version++,_s++,this.notify(t)}notify(t){Ol();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{Rl()}}}function hi(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let s=t.deps;s;s=s.nextDep)hi(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Js=new WeakMap,An=Symbol(""),nl=Symbol(""),ys=Symbol("");function lt(e,t,n){if(Tt&&Ne){let s=Js.get(e);s||Js.set(e,s=new Map);let l=s.get(n);l||(s.set(n,l=new Fl),l.map=s,l.key=n),l.track()}}function qt(e,t,n,s,l,o){const r=Js.get(e);if(!r){_s++;return}const a=i=>{i&&i.trigger()};if(Ol(),t==="clear")r.forEach(a);else{const i=re(e),u=i&&Pl(n);if(i&&n==="length"){const f=Number(s);r.forEach((d,m)=>{(m==="length"||m===ys||!Lt(m)&&m>=f)&&a(d)})}else switch((n!==void 0||r.has(void 0))&&a(r.get(n)),u&&a(r.get(ys)),t){case"add":i?u&&a(r.get("length")):(a(r.get(An)),Yn(e)&&a(r.get(nl)));break;case"delete":i||(a(r.get(An)),Yn(e)&&a(r.get(nl)));break;case"set":Yn(e)&&a(r.get(An));break}}Rl()}function Nu(e,t){const n=Js.get(e);return n&&n.get(t)}function Fn(e){const t=we(e);return t===e?t:(lt(t,"iterate",ys),xt(e)?t:t.map(Je))}function bo(e){return lt(e=we(e),"iterate",ys),e}const Iu={__proto__:null,[Symbol.iterator](){return Fo(this,Symbol.iterator,Je)},concat(...e){return Fn(this).concat(...e.map(t=>re(t)?Fn(t):t))},entries(){return Fo(this,"entries",e=>(e[1]=Je(e[1]),e))},every(e,t){return Ht(this,"every",e,t,void 0,arguments)},filter(e,t){return Ht(this,"filter",e,t,n=>n.map(Je),arguments)},find(e,t){return Ht(this,"find",e,t,Je,arguments)},findIndex(e,t){return Ht(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return Ht(this,"findLast",e,t,Je,arguments)},findLastIndex(e,t){return Ht(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return Ht(this,"forEach",e,t,void 0,arguments)},includes(...e){return Uo(this,"includes",e)},indexOf(...e){return Uo(this,"indexOf",e)},join(e){return Fn(this).join(e)},lastIndexOf(...e){return Uo(this,"lastIndexOf",e)},map(e,t){return Ht(this,"map",e,t,void 0,arguments)},pop(){return ls(this,"pop")},push(...e){return ls(this,"push",e)},reduce(e,...t){return pr(this,"reduce",e,t)},reduceRight(e,...t){return pr(this,"reduceRight",e,t)},shift(){return ls(this,"shift")},some(e,t){return Ht(this,"some",e,t,void 0,arguments)},splice(...e){return ls(this,"splice",e)},toReversed(){return Fn(this).toReversed()},toSorted(e){return Fn(this).toSorted(e)},toSpliced(...e){return Fn(this).toSpliced(...e)},unshift(...e){return ls(this,"unshift",e)},values(){return Fo(this,"values",Je)}};function Fo(e,t,n){const s=bo(e),l=s[t]();return s!==e&&!xt(e)&&(l._next=l.next,l.next=()=>{const o=l._next();return o.done||(o.value=n(o.value)),o}),l}const Pu=Array.prototype;function Ht(e,t,n,s,l,o){const r=bo(e),a=r!==e&&!xt(e),i=r[t];if(i!==Pu[t]){const d=i.apply(e,o);return a?Je(d):d}let u=n;r!==e&&(a?u=function(d,m){return n.call(this,Je(d),m,e)}:n.length>2&&(u=function(d,m){return n.call(this,d,m,e)}));const f=i.call(r,u,s);return a&&l?l(f):f}function pr(e,t,n,s){const l=bo(e);let o=n;return l!==e&&(xt(e)?n.length>3&&(o=function(r,a,i){return n.call(this,r,a,i,e)}):o=function(r,a,i){return n.call(this,r,Je(a),i,e)}),l[t](o,...s)}function Uo(e,t,n){const s=we(e);lt(s,"iterate",ys);const l=s[t](...n);return(l===-1||l===!1)&&Hl(n[0])?(n[0]=we(n[0]),s[t](...n)):l}function ls(e,t,n=[]){Zt(),Ol();const s=we(e)[t].apply(e,n);return Rl(),en(),s}const Au=$l("__proto__,__v_isRef,__isVue"),gi=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Lt));function Du(e){Lt(e)||(e=String(e));const t=we(this);return lt(t,"has",e),t.hasOwnProperty(e)}class vi{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){if(n==="__v_skip")return t.__v_skip;const l=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!l;if(n==="__v_isReadonly")return l;if(n==="__v_isShallow")return o;if(n==="__v_raw")return s===(l?o?Bu:wi:o?yi:_i).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const r=re(t);if(!l){let i;if(r&&(i=Iu[n]))return i;if(n==="hasOwnProperty")return Du}const a=Reflect.get(t,n,Ve(t)?t:s);if((Lt(n)?gi.has(n):Au(n))||(l||lt(t,"get",n),o))return a;if(Ve(a)){const i=r&&Pl(n)?a:a.value;return l&&Le(i)?ol(i):i}return Le(a)?l?ol(a):Ds(a):a}}class bi extends vi{constructor(t=!1){super(!1,t)}set(t,n,s,l){let o=t[n];if(!this._isShallow){const i=mn(o);if(!xt(s)&&!mn(s)&&(o=we(o),s=we(s)),!re(t)&&Ve(o)&&!Ve(s))return i||(o.value=s),!0}const r=re(t)&&Pl(n)?Number(n)<t.length:Ce(t,n),a=Reflect.set(t,n,s,Ve(t)?t:l);return t===we(l)&&(r?fn(s,o)&&qt(t,"set",n,s):qt(t,"add",n,s)),a}deleteProperty(t,n){const s=Ce(t,n);t[n];const l=Reflect.deleteProperty(t,n);return l&&s&&qt(t,"delete",n,void 0),l}has(t,n){const s=Reflect.has(t,n);return(!Lt(n)||!gi.has(n))&<(t,"has",n),s}ownKeys(t){return lt(t,"iterate",re(t)?"length":An),Reflect.ownKeys(t)}}class Ou extends vi{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const Ru=new bi,Mu=new Ou,Fu=new bi(!0);const sl=e=>e,Hs=e=>Reflect.getPrototypeOf(e);function Uu(e,t,n){return function(...s){const l=this.__v_raw,o=we(l),r=Yn(o),a=e==="entries"||e===Symbol.iterator&&r,i=e==="keys"&&r,u=l[e](...s),f=n?sl:t?Zs:Je;return!t&<(o,"iterate",i?nl:An),{next(){const{value:d,done:m}=u.next();return m?{value:d,done:m}:{value:a?[f(d[0]),f(d[1])]:f(d),done:m}},[Symbol.iterator](){return this}}}}function Ws(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Vu(e,t){const n={get(l){const o=this.__v_raw,r=we(o),a=we(l);e||(fn(l,a)&<(r,"get",l),lt(r,"get",a));const{has:i}=Hs(r),u=t?sl:e?Zs:Je;if(i.call(r,l))return u(o.get(l));if(i.call(r,a))return u(o.get(a));o!==r&&o.get(l)},get size(){const l=this.__v_raw;return!e&<(we(l),"iterate",An),l.size},has(l){const o=this.__v_raw,r=we(o),a=we(l);return e||(fn(l,a)&<(r,"has",l),lt(r,"has",a)),l===a?o.has(l):o.has(l)||o.has(a)},forEach(l,o){const r=this,a=r.__v_raw,i=we(a),u=t?sl:e?Zs:Je;return!e&<(i,"iterate",An),a.forEach((f,d)=>l.call(o,u(f),u(d),r))}};return qe(n,e?{add:Ws("add"),set:Ws("set"),delete:Ws("delete"),clear:Ws("clear")}:{add(l){!t&&!xt(l)&&!mn(l)&&(l=we(l));const o=we(this);return Hs(o).has.call(o,l)||(o.add(l),qt(o,"add",l,l)),this},set(l,o){!t&&!xt(o)&&!mn(o)&&(o=we(o));const r=we(this),{has:a,get:i}=Hs(r);let u=a.call(r,l);u||(l=we(l),u=a.call(r,l));const f=i.call(r,l);return r.set(l,o),u?fn(o,f)&&qt(r,"set",l,o):qt(r,"add",l,o),this},delete(l){const o=we(this),{has:r,get:a}=Hs(o);let i=r.call(o,l);i||(l=we(l),i=r.call(o,l)),a&&a.call(o,l);const u=o.delete(l);return i&&qt(o,"delete",l,void 0),u},clear(){const l=we(this),o=l.size!==0,r=l.clear();return o&&qt(l,"clear",void 0,void 0),r}}),["keys","values","entries",Symbol.iterator].forEach(l=>{n[l]=Uu(l,e,t)}),n}function Ul(e,t){const n=Vu(e,t);return(s,l,o)=>l==="__v_isReactive"?!e:l==="__v_isReadonly"?e:l==="__v_raw"?s:Reflect.get(Ce(n,l)&&l in s?n:s,l,o)}const Hu={get:Ul(!1,!1)},Wu={get:Ul(!1,!0)},ju={get:Ul(!0,!1)};const _i=new WeakMap,yi=new WeakMap,wi=new WeakMap,Bu=new WeakMap;function Gu(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Ku(e){return e.__v_skip||!Object.isExtensible(e)?0:Gu(gu(e))}function Ds(e){return mn(e)?e:Vl(e,!1,Ru,Hu,_i)}function xi(e){return Vl(e,!1,Fu,Wu,yi)}function ol(e){return Vl(e,!0,Mu,ju,wi)}function Vl(e,t,n,s,l){if(!Le(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=Ku(e);if(o===0)return e;const r=l.get(e);if(r)return r;const a=new Proxy(e,o===2?s:n);return l.set(e,a),a}function dn(e){return mn(e)?dn(e.__v_raw):!!(e&&e.__v_isReactive)}function mn(e){return!!(e&&e.__v_isReadonly)}function xt(e){return!!(e&&e.__v_isShallow)}function Hl(e){return e?!!e.__v_raw:!1}function we(e){const t=e&&e.__v_raw;return t?we(t):e}function Wl(e){return!Ce(e,"__v_skip")&&Object.isExtensible(e)&&ni(e,"__v_skip",!0),e}const Je=e=>Le(e)?Ds(e):e,Zs=e=>Le(e)?ol(e):e;function Ve(e){return e?e.__v_isRef===!0:!1}function q(e){return Ei(e,!1)}function jl(e){return Ei(e,!0)}function Ei(e,t){return Ve(e)?e:new Yu(e,t)}class Yu{constructor(t,n){this.dep=new Fl,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:we(t),this._value=n?t:Je(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||xt(t)||mn(t);t=s?t:we(t),fn(t,n)&&(this._rawValue=t,this._value=s?t:Je(t),this.dep.trigger())}}function ke(e){return Ve(e)?e.value:e}const qu={get:(e,t,n)=>t==="__v_raw"?e:ke(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const l=e[t];return Ve(l)&&!Ve(n)?(l.value=n,!0):Reflect.set(e,t,n,s)}};function ki(e){return dn(e)?e:new Proxy(e,qu)}function Xu(e){const t=re(e)?new Array(e.length):{};for(const n in e)t[n]=Qu(e,n);return t}class zu{constructor(t,n,s){this._object=t,this._key=n,this._defaultValue=s,this.__v_isRef=!0,this._value=void 0}get value(){const t=this._object[this._key];return this._value=t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return Nu(we(this._object),this._key)}}function Qu(e,t,n){const s=e[t];return Ve(s)?s:new zu(e,t,n)}class Ju{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new Fl(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=_s-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&Ne!==this)return ui(this,!0),!0}get value(){const t=this.dep.track();return mi(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function Zu(e,t,n=!1){let s,l;return ue(e)?s=e:(s=e.get,l=e.set),new Ju(s,l,n)}const js={},eo=new WeakMap;let $n;function ef(e,t=!1,n=$n){if(n){let s=eo.get(n);s||eo.set(n,s=[]),s.push(e)}}function tf(e,t,n=$e){const{immediate:s,deep:l,once:o,scheduler:r,augmentJob:a,call:i}=n,u=v=>l?v:xt(v)||l===!1||l===0?Xt(v,1):Xt(v);let f,d,m,g,C=!1,k=!1;if(Ve(e)?(d=()=>e.value,C=xt(e)):dn(e)?(d=()=>u(e),C=!0):re(e)?(k=!0,C=e.some(v=>dn(v)||xt(v)),d=()=>e.map(v=>{if(Ve(v))return v.value;if(dn(v))return u(v);if(ue(v))return i?i(v,2):v()})):ue(e)?t?d=i?()=>i(e,2):e:d=()=>{if(m){Zt();try{m()}finally{en()}}const v=$n;$n=f;try{return i?i(e,3,[g]):e(g)}finally{$n=v}}:d=Rt,t&&l){const v=d,T=l===!0?1/0:l;d=()=>Xt(v(),T)}const N=ai(),O=()=>{f.stop(),N&&N.active&&Il(N.effects,f)};if(o&&t){const v=t;t=(...T)=>{v(...T),O()}}let I=k?new Array(e.length).fill(js):js;const b=v=>{if(!(!(f.flags&1)||!f.dirty&&!v))if(t){const T=f.run();if(l||C||(k?T.some(($,S)=>fn($,I[S])):fn(T,I))){m&&m();const $=$n;$n=f;try{const S=[T,I===js?void 0:k&&I[0]===js?[]:I,g];I=T,i?i(t,3,S):t(...S)}finally{$n=$}}}else f.run()};return a&&a(b),f=new ii(d),f.scheduler=r?()=>r(b,!1):b,g=v=>ef(v,!1,f),m=f.onStop=()=>{const v=eo.get(f);if(v){if(i)i(v,4);else for(const T of v)T();eo.delete(f)}},t?s?b(!0):I=f.run():r?r(b.bind(null,!0),!0):f.run(),O.pause=f.pause.bind(f),O.resume=f.resume.bind(f),O.stop=O,O}function Xt(e,t=1/0,n){if(t<=0||!Le(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,Ve(e))Xt(e.value,t,n);else if(re(e))for(let s=0;s<e.length;s++)Xt(e[s],t,n);else if(ns(e)||Yn(e))e.forEach(s=>{Xt(s,t,n)});else if(ti(e)){for(const s in e)Xt(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&Xt(e[s],t,n)}return e}function Os(e,t,n,s){try{return s?e(...s):e()}catch(l){_o(l,t,n)}}function $t(e,t,n,s){if(ue(e)){const l=Os(e,t,n,s);return l&&Za(l)&&l.catch(o=>{_o(o,t,n)}),l}if(re(e)){const l=[];for(let o=0;o<e.length;o++)l.push($t(e[o],t,n,s));return l}}function _o(e,t,n,s=!0){const l=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:r}=t&&t.appContext.config||$e;if(t){let a=t.parent;const i=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${n}`;for(;a;){const f=a.ec;if(f){for(let d=0;d<f.length;d++)if(f[d](e,i,u)===!1)return}a=a.parent}if(o){Zt(),Os(o,null,10,[e,i,u]),en();return}}nf(e,n,l,s,r)}function nf(e,t,n,s=!0,l=!1){if(l)throw e;console.error(e)}const dt=[];let At=-1;const qn=[];let rn=null,Vn=0;const Ci=Promise.resolve();let to=null;function Rs(e){const t=to||Ci;return e?t.then(this?e.bind(this):e):t}function sf(e){let t=At+1,n=dt.length;for(;t<n;){const s=t+n>>>1,l=dt[s],o=ws(l);o<e||o===e&&l.flags&2?t=s+1:n=s}return t}function Bl(e){if(!(e.flags&1)){const t=ws(e),n=dt[dt.length-1];!n||!(e.flags&2)&&t>=ws(n)?dt.push(e):dt.splice(sf(t),0,e),e.flags|=1,Si()}}function Si(){to||(to=Ci.then(Li))}function of(e){re(e)?qn.push(...e):rn&&e.id===-1?rn.splice(Vn+1,0,e):e.flags&1||(qn.push(e),e.flags|=1),Si()}function hr(e,t,n=At+1){for(;n<dt.length;n++){const s=dt[n];if(s&&s.flags&2){if(e&&s.id!==e.uid)continue;dt.splice(n,1),n--,s.flags&4&&(s.flags&=-2),s(),s.flags&4||(s.flags&=-2)}}}function Ti(e){if(qn.length){const t=[...new Set(qn)].sort((n,s)=>ws(n)-ws(s));if(qn.length=0,rn){rn.push(...t);return}for(rn=t,Vn=0;Vn<rn.length;Vn++){const n=rn[Vn];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}rn=null,Vn=0}}const ws=e=>e.id==null?e.flags&2?-1:1/0:e.id;function Li(e){try{for(At=0;At<dt.length;At++){const t=dt[At];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),Os(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;At<dt.length;At++){const t=dt[At];t&&(t.flags&=-2)}At=-1,dt.length=0,Ti(),to=null,(dt.length||qn.length)&&Li()}}let Ze=null,$i=null;function no(e){const t=Ze;return Ze=e,$i=e&&e.type.__scopeId||null,t}function Ft(e,t=Ze,n){if(!t||e._n)return e;const s=(...l)=>{s._d&&lo(-1);const o=no(t);let r;try{r=e(...l)}finally{no(o),s._d&&lo(1)}return r};return s._n=!0,s._c=!0,s._d=!0,s}function Fe(e,t){if(Ze===null)return e;const n=ko(Ze),s=e.dirs||(e.dirs=[]);for(let l=0;l<t.length;l++){let[o,r,a,i=$e]=t[l];o&&(ue(o)&&(o={mounted:o,updated:o}),o.deep&&Xt(r),s.push({dir:o,instance:n,value:r,oldValue:void 0,arg:a,modifiers:i}))}return e}function En(e,t,n,s){const l=e.dirs,o=t&&t.dirs;for(let r=0;r<l.length;r++){const a=l[r];o&&(a.oldValue=o[r].value);let i=a.dir[s];i&&(Zt(),$t(i,n,8,[e.el,a,e,t]),en())}}const lf=Symbol("_vte"),Ni=e=>e.__isTeleport,Yt=Symbol("_leaveCb"),Bs=Symbol("_enterCb");function rf(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Vt(()=>{e.isMounted=!0}),Ui(()=>{e.isUnmounting=!0}),e}const yt=[Function,Array],Ii={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:yt,onEnter:yt,onAfterEnter:yt,onEnterCancelled:yt,onBeforeLeave:yt,onLeave:yt,onAfterLeave:yt,onLeaveCancelled:yt,onBeforeAppear:yt,onAppear:yt,onAfterAppear:yt,onAppearCancelled:yt},Pi=e=>{const t=e.subTree;return t.component?Pi(t.component):t},af={name:"BaseTransition",props:Ii,setup(e,{slots:t}){const n=hn(),s=rf();return()=>{const l=t.default&&Oi(t.default(),!0);if(!l||!l.length)return;const o=Ai(l),r=we(e),{mode:a}=r;if(s.isLeaving)return Vo(o);const i=gr(o);if(!i)return Vo(o);let u=ll(i,r,s,n,d=>u=d);i.type!==rt&&xs(i,u);let f=n.subTree&&gr(n.subTree);if(f&&f.type!==rt&&!In(f,i)&&Pi(n).type!==rt){let d=ll(f,r,s,n);if(xs(f,d),a==="out-in"&&i.type!==rt)return s.isLeaving=!0,d.afterLeave=()=>{s.isLeaving=!1,n.job.flags&8||n.update(),delete d.afterLeave,f=void 0},Vo(o);a==="in-out"&&i.type!==rt?d.delayLeave=(m,g,C)=>{const k=Di(s,f);k[String(f.key)]=f,m[Yt]=()=>{g(),m[Yt]=void 0,delete u.delayedLeave,f=void 0},u.delayedLeave=()=>{C(),delete u.delayedLeave,f=void 0}}:f=void 0}else f&&(f=void 0);return o}}};function Ai(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==rt){t=n;break}}return t}const cf=af;function Di(e,t){const{leavingVNodes:n}=e;let s=n.get(t.type);return s||(s=Object.create(null),n.set(t.type,s)),s}function ll(e,t,n,s,l){const{appear:o,mode:r,persisted:a=!1,onBeforeEnter:i,onEnter:u,onAfterEnter:f,onEnterCancelled:d,onBeforeLeave:m,onLeave:g,onAfterLeave:C,onLeaveCancelled:k,onBeforeAppear:N,onAppear:O,onAfterAppear:I,onAppearCancelled:b}=t,v=String(e.key),T=Di(n,e),$=(x,H)=>{x&&$t(x,s,9,H)},S=(x,H)=>{const M=H[1];$(x,H),re(x)?x.every(P=>P.length<=1)&&M():x.length<=1&&M()},L={mode:r,persisted:a,beforeEnter(x){let H=i;if(!n.isMounted)if(o)H=N||i;else return;x[Yt]&&x[Yt](!0);const M=T[v];M&&In(e,M)&&M.el[Yt]&&M.el[Yt](),$(H,[x])},enter(x){let H=u,M=f,P=d;if(!n.isMounted)if(o)H=O||u,M=I||f,P=b||d;else return;let Y=!1;const Se=x[Bs]=Re=>{Y||(Y=!0,Re?$(P,[x]):$(M,[x]),L.delayedLeave&&L.delayedLeave(),x[Bs]=void 0)};H?S(H,[x,Se]):Se()},leave(x,H){const M=String(e.key);if(x[Bs]&&x[Bs](!0),n.isUnmounting)return H();$(m,[x]);let P=!1;const Y=x[Yt]=Se=>{P||(P=!0,H(),Se?$(k,[x]):$(C,[x]),x[Yt]=void 0,T[M]===e&&delete T[M])};T[M]=e,g?S(g,[x,Y]):Y()},clone(x){const H=ll(x,t,n,s,l);return l&&l(H),H}};return L}function Vo(e){if(yo(e))return e=pn(e),e.children=null,e}function gr(e){if(!yo(e))return Ni(e.type)&&e.children?Ai(e.children):e;if(e.component)return e.component.subTree;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&ue(n.default))return n.default()}}function xs(e,t){e.shapeFlag&6&&e.component?(e.transition=t,xs(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Oi(e,t=!1,n){let s=[],l=0;for(let o=0;o<e.length;o++){let r=e[o];const a=n==null?r.key:String(n)+String(r.key!=null?r.key:o);r.type===Ge?(r.patchFlag&128&&l++,s=s.concat(Oi(r.children,t,a))):(t||r.type!==rt)&&s.push(a!=null?pn(r,{key:a}):r)}if(l>1)for(let o=0;o<s.length;o++)s[o].patchFlag=-2;return s}function Oe(e,t){return ue(e)?qe({name:e.name},t,{setup:e}):e}function Ri(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}const so=new WeakMap;function ms(e,t,n,s,l=!1){if(re(e)){e.forEach((C,k)=>ms(C,t&&(re(t)?t[k]:t),n,s,l));return}if(Xn(s)&&!l){s.shapeFlag&512&&s.type.__asyncResolved&&s.component.subTree.component&&ms(e,t,n,s.component.subTree);return}const o=s.shapeFlag&4?ko(s.component):s.el,r=l?null:o,{i:a,r:i}=e,u=t&&t.r,f=a.refs===$e?a.refs={}:a.refs,d=a.setupState,m=we(d),g=d===$e?Ja:C=>Ce(m,C);if(u!=null&&u!==i){if(vr(t),We(u))f[u]=null,g(u)&&(d[u]=null);else if(Ve(u)){u.value=null;const C=t;C.k&&(f[C.k]=null)}}if(ue(i))Os(i,a,12,[r,f]);else{const C=We(i),k=Ve(i);if(C||k){const N=()=>{if(e.f){const O=C?g(i)?d[i]:f[i]:i.value;if(l)re(O)&&Il(O,o);else if(re(O))O.includes(o)||O.push(o);else if(C)f[i]=[o],g(i)&&(d[i]=f[i]);else{const I=[o];i.value=I,e.k&&(f[e.k]=I)}}else C?(f[i]=r,g(i)&&(d[i]=r)):k&&(i.value=r,e.k&&(f[e.k]=r))};if(r){const O=()=>{N(),so.delete(e)};O.id=-1,so.set(e,O),bt(O,n)}else vr(e),N()}}}function vr(e){const t=so.get(e);t&&(t.flags|=8,so.delete(e))}go().requestIdleCallback;go().cancelIdleCallback;const Xn=e=>!!e.type.__asyncLoader,yo=e=>e.type.__isKeepAlive;function uf(e,t){Mi(e,"a",t)}function ff(e,t){Mi(e,"da",t)}function Mi(e,t,n=at){const s=e.__wdc||(e.__wdc=()=>{let l=n;for(;l;){if(l.isDeactivated)return;l=l.parent}return e()});if(wo(t,s,n),n){let l=n.parent;for(;l&&l.parent;)yo(l.parent.vnode)&&df(s,t,n,l),l=l.parent}}function df(e,t,n,s){const l=wo(t,e,s,!0);On(()=>{Il(s[t],l)},n)}function wo(e,t,n=at,s=!1){if(n){const l=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...r)=>{Zt();const a=Fs(n),i=$t(t,n,e,r);return a(),en(),i});return s?l.unshift(o):l.push(o),o}}const tn=e=>(t,n=at)=>{(!Cs||e==="sp")&&wo(e,(...s)=>t(...s),n)},Fi=tn("bm"),Vt=tn("m"),mf=tn("bu"),pf=tn("u"),Ui=tn("bum"),On=tn("um"),hf=tn("sp"),gf=tn("rtg"),vf=tn("rtc");function bf(e,t=at){wo("ec",e,t)}const _f="components";function yf(e,t){return xf(_f,e,!0,t)||e}const wf=Symbol.for("v-ndc");function xf(e,t,n=!0,s=!1){const l=Ze||at;if(l){const o=l.type;{const a=ud(o,!1);if(a&&(a===t||a===Et(t)||a===po(Et(t))))return o}const r=br(l[e]||o[e],t)||br(l.appContext[e],t);return!r&&s?o:r}}function br(e,t){return e&&(e[t]||e[Et(t)]||e[po(Et(t))])}function xo(e,t,n,s){let l;const o=n,r=re(e);if(r||We(e)){const a=r&&dn(e);let i=!1,u=!1;a&&(i=!xt(e),u=mn(e),e=bo(e)),l=new Array(e.length);for(let f=0,d=e.length;f<d;f++)l[f]=t(i?u?Zs(Je(e[f])):Je(e[f]):e[f],f,void 0,o)}else if(typeof e=="number"){l=new Array(e);for(let a=0;a<e;a++)l[a]=t(a+1,a,void 0,o)}else if(Le(e))if(e[Symbol.iterator])l=Array.from(e,(a,i)=>t(a,i,void 0,o));else{const a=Object.keys(e);l=new Array(a.length);for(let i=0,u=a.length;i<u;i++){const f=a[i];l[i]=t(e[f],f,i,o)}}else l=[];return l}function Vi(e,t,n={},s,l){if(Ze.ce||Ze.parent&&Xn(Ze.parent)&&Ze.parent.ce){const u=Object.keys(n).length>0;return K(),Ut(Ge,null,[ye("slot",n,s&&s())],u?-2:64)}let o=e[t];o&&o._c&&(o._d=!1),K();const r=o&&Hi(o(n)),a=n.key||r&&r.key,i=Ut(Ge,{key:(a&&!Lt(a)?a:`_${t}`)+(!r&&s?"_fb":"")},r||(s?s():[]),r&&e._===1?64:-2);return!l&&i.scopeId&&(i.slotScopeIds=[i.scopeId+"-s"]),o&&o._c&&(o._d=!0),i}function Hi(e){return e.some(t=>ks(t)?!(t.type===rt||t.type===Ge&&!Hi(t.children)):!0)?e:null}const rl=e=>e?ac(e)?ko(e):rl(e.parent):null,ps=qe(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=>rl(e.parent),$root:e=>rl(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>ji(e),$forceUpdate:e=>e.f||(e.f=()=>{Bl(e.update)}),$nextTick:e=>e.n||(e.n=Rs.bind(e.proxy)),$watch:e=>Bf.bind(e)}),Ho=(e,t)=>e!==$e&&!e.__isScriptSetup&&Ce(e,t),Ef={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:l,props:o,accessCache:r,type:a,appContext:i}=e;let u;if(t[0]!=="$"){const g=r[t];if(g!==void 0)switch(g){case 1:return s[t];case 2:return l[t];case 4:return n[t];case 3:return o[t]}else{if(Ho(s,t))return r[t]=1,s[t];if(l!==$e&&Ce(l,t))return r[t]=2,l[t];if((u=e.propsOptions[0])&&Ce(u,t))return r[t]=3,o[t];if(n!==$e&&Ce(n,t))return r[t]=4,n[t];al&&(r[t]=0)}}const f=ps[t];let d,m;if(f)return t==="$attrs"&<(e.attrs,"get",""),f(e);if((d=a.__cssModules)&&(d=d[t]))return d;if(n!==$e&&Ce(n,t))return r[t]=4,n[t];if(m=i.config.globalProperties,Ce(m,t))return m[t]},set({_:e},t,n){const{data:s,setupState:l,ctx:o}=e;return Ho(l,t)?(l[t]=n,!0):s!==$e&&Ce(s,t)?(s[t]=n,!0):Ce(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:l,propsOptions:o,type:r}},a){let i,u;return!!(n[a]||e!==$e&&a[0]!=="$"&&Ce(e,a)||Ho(t,a)||(i=o[0])&&Ce(i,a)||Ce(s,a)||Ce(ps,a)||Ce(l.config.globalProperties,a)||(u=r.__cssModules)&&u[a])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Ce(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function _r(e){return re(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let al=!0;function kf(e){const t=ji(e),n=e.proxy,s=e.ctx;al=!1,t.beforeCreate&&yr(t.beforeCreate,e,"bc");const{data:l,computed:o,methods:r,watch:a,provide:i,inject:u,created:f,beforeMount:d,mounted:m,beforeUpdate:g,updated:C,activated:k,deactivated:N,beforeDestroy:O,beforeUnmount:I,destroyed:b,unmounted:v,render:T,renderTracked:$,renderTriggered:S,errorCaptured:L,serverPrefetch:x,expose:H,inheritAttrs:M,components:P,directives:Y,filters:Se}=t;if(u&&Cf(u,s,null),r)for(const ae in r){const pe=r[ae];ue(pe)&&(s[ae]=pe.bind(n))}if(l){const ae=l.call(n,n);Le(ae)&&(e.data=Ds(ae))}if(al=!0,o)for(const ae in o){const pe=o[ae],Xe=ue(pe)?pe.bind(n,n):ue(pe.get)?pe.get.bind(n,n):Rt,tt=!ue(pe)&&ue(pe.set)?pe.set.bind(n):Rt,Ae=fe({get:Xe,set:tt});Object.defineProperty(s,ae,{enumerable:!0,configurable:!0,get:()=>Ae.value,set:De=>Ae.value=De})}if(a)for(const ae in a)Wi(a[ae],s,n,ae);if(i){const ae=ue(i)?i.call(n):i;Reflect.ownKeys(ae).forEach(pe=>{hs(pe,ae[pe])})}f&&yr(f,e,"c");function de(ae,pe){re(pe)?pe.forEach(Xe=>ae(Xe.bind(n))):pe&&ae(pe.bind(n))}if(de(Fi,d),de(Vt,m),de(mf,g),de(pf,C),de(uf,k),de(ff,N),de(bf,L),de(vf,$),de(gf,S),de(Ui,I),de(On,v),de(hf,x),re(H))if(H.length){const ae=e.exposed||(e.exposed={});H.forEach(pe=>{Object.defineProperty(ae,pe,{get:()=>n[pe],set:Xe=>n[pe]=Xe,enumerable:!0})})}else e.exposed||(e.exposed={});T&&e.render===Rt&&(e.render=T),M!=null&&(e.inheritAttrs=M),P&&(e.components=P),Y&&(e.directives=Y),x&&Ri(e)}function Cf(e,t,n=Rt){re(e)&&(e=il(e));for(const s in e){const l=e[s];let o;Le(l)?"default"in l?o=gt(l.from||s,l.default,!0):o=gt(l.from||s):o=gt(l),Ve(o)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>o.value,set:r=>o.value=r}):t[s]=o}}function yr(e,t,n){$t(re(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function Wi(e,t,n,s){let l=s.includes(".")?nc(n,s):()=>n[s];if(We(e)){const o=t[e];ue(o)&&mt(l,o)}else if(ue(e))mt(l,e.bind(n));else if(Le(e))if(re(e))e.forEach(o=>Wi(o,t,n,s));else{const o=ue(e.handler)?e.handler.bind(n):t[e.handler];ue(o)&&mt(l,o,e)}}function ji(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:l,optionsCache:o,config:{optionMergeStrategies:r}}=e.appContext,a=o.get(t);let i;return a?i=a:!l.length&&!n&&!s?i=t:(i={},l.length&&l.forEach(u=>oo(i,u,r,!0)),oo(i,t,r)),Le(t)&&o.set(t,i),i}function oo(e,t,n,s=!1){const{mixins:l,extends:o}=t;o&&oo(e,o,n,!0),l&&l.forEach(r=>oo(e,r,n,!0));for(const r in t)if(!(s&&r==="expose")){const a=Sf[r]||n&&n[r];e[r]=a?a(e[r],t[r]):t[r]}return e}const Sf={data:wr,props:xr,emits:xr,methods:cs,computed:cs,beforeCreate:ct,created:ct,beforeMount:ct,mounted:ct,beforeUpdate:ct,updated:ct,beforeDestroy:ct,beforeUnmount:ct,destroyed:ct,unmounted:ct,activated:ct,deactivated:ct,errorCaptured:ct,serverPrefetch:ct,components:cs,directives:cs,watch:Lf,provide:wr,inject:Tf};function wr(e,t){return t?e?function(){return qe(ue(e)?e.call(this,this):e,ue(t)?t.call(this,this):t)}:t:e}function Tf(e,t){return cs(il(e),il(t))}function il(e){if(re(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function ct(e,t){return e?[...new Set([].concat(e,t))]:t}function cs(e,t){return e?qe(Object.create(null),e,t):t}function xr(e,t){return e?re(e)&&re(t)?[...new Set([...e,...t])]:qe(Object.create(null),_r(e),_r(t??{})):t}function Lf(e,t){if(!e)return t;if(!t)return e;const n=qe(Object.create(null),e);for(const s in t)n[s]=ct(e[s],t[s]);return n}function Bi(){return{app:null,config:{isNativeTag:Ja,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 $f=0;function Nf(e,t){return function(s,l=null){ue(s)||(s=qe({},s)),l!=null&&!Le(l)&&(l=null);const o=Bi(),r=new WeakSet,a=[];let i=!1;const u=o.app={_uid:$f++,_component:s,_props:l,_container:null,_context:o,_instance:null,version:dd,get config(){return o.config},set config(f){},use(f,...d){return r.has(f)||(f&&ue(f.install)?(r.add(f),f.install(u,...d)):ue(f)&&(r.add(f),f(u,...d))),u},mixin(f){return o.mixins.includes(f)||o.mixins.push(f),u},component(f,d){return d?(o.components[f]=d,u):o.components[f]},directive(f,d){return d?(o.directives[f]=d,u):o.directives[f]},mount(f,d,m){if(!i){const g=u._ceVNode||ye(s,l);return g.appContext=o,m===!0?m="svg":m===!1&&(m=void 0),e(g,f,m),i=!0,u._container=f,f.__vue_app__=u,ko(g.component)}},onUnmount(f){a.push(f)},unmount(){i&&($t(a,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(f,d){return o.provides[f]=d,u},runWithContext(f){const d=Dn;Dn=u;try{return f()}finally{Dn=d}}};return u}}let Dn=null;function hs(e,t){if(at){let n=at.provides;const s=at.parent&&at.parent.provides;s===n&&(n=at.provides=Object.create(s)),n[e]=t}}function gt(e,t,n=!1){const s=hn();if(s||Dn){let l=Dn?Dn._context.provides:s?s.parent==null||s.ce?s.vnode.appContext&&s.vnode.appContext.provides:s.parent.provides:void 0;if(l&&e in l)return l[e];if(arguments.length>1)return n&&ue(t)?t.call(s&&s.proxy):t}}function If(){return!!(hn()||Dn)}const Gi={},Ki=()=>Object.create(Gi),Yi=e=>Object.getPrototypeOf(e)===Gi;function Pf(e,t,n,s=!1){const l={},o=Ki();e.propsDefaults=Object.create(null),qi(e,t,l,o);for(const r in e.propsOptions[0])r in l||(l[r]=void 0);n?e.props=s?l:xi(l):e.type.props?e.props=l:e.props=o,e.attrs=o}function Af(e,t,n,s){const{props:l,attrs:o,vnode:{patchFlag:r}}=e,a=we(l),[i]=e.propsOptions;let u=!1;if((s||r>0)&&!(r&16)){if(r&8){const f=e.vnode.dynamicProps;for(let d=0;d<f.length;d++){let m=f[d];if(Eo(e.emitsOptions,m))continue;const g=t[m];if(i)if(Ce(o,m))g!==o[m]&&(o[m]=g,u=!0);else{const C=Et(m);l[C]=cl(i,a,C,g,e,!1)}else g!==o[m]&&(o[m]=g,u=!0)}}}else{qi(e,t,l,o)&&(u=!0);let f;for(const d in a)(!t||!Ce(t,d)&&((f=bn(d))===d||!Ce(t,f)))&&(i?n&&(n[d]!==void 0||n[f]!==void 0)&&(l[d]=cl(i,a,d,void 0,e,!0)):delete l[d]);if(o!==a)for(const d in o)(!t||!Ce(t,d))&&(delete o[d],u=!0)}u&&qt(e.attrs,"set","")}function qi(e,t,n,s){const[l,o]=e.propsOptions;let r=!1,a;if(t)for(let i in t){if(us(i))continue;const u=t[i];let f;l&&Ce(l,f=Et(i))?!o||!o.includes(f)?n[f]=u:(a||(a={}))[f]=u:Eo(e.emitsOptions,i)||(!(i in s)||u!==s[i])&&(s[i]=u,r=!0)}if(o){const i=we(n),u=a||$e;for(let f=0;f<o.length;f++){const d=o[f];n[d]=cl(l,i,d,u[d],e,!Ce(u,d))}}return r}function cl(e,t,n,s,l,o){const r=e[n];if(r!=null){const a=Ce(r,"default");if(a&&s===void 0){const i=r.default;if(r.type!==Function&&!r.skipFactory&&ue(i)){const{propsDefaults:u}=l;if(n in u)s=u[n];else{const f=Fs(l);s=u[n]=i.call(null,t),f()}}else s=i;l.ce&&l.ce._setProp(n,s)}r[0]&&(o&&!a?s=!1:r[1]&&(s===""||s===bn(n))&&(s=!0))}return s}const Df=new WeakMap;function Xi(e,t,n=!1){const s=n?Df:t.propsCache,l=s.get(e);if(l)return l;const o=e.props,r={},a=[];let i=!1;if(!ue(e)){const f=d=>{i=!0;const[m,g]=Xi(d,t,!0);qe(r,m),g&&a.push(...g)};!n&&t.mixins.length&&t.mixins.forEach(f),e.extends&&f(e.extends),e.mixins&&e.mixins.forEach(f)}if(!o&&!i)return Le(e)&&s.set(e,Kn),Kn;if(re(o))for(let f=0;f<o.length;f++){const d=Et(o[f]);Er(d)&&(r[d]=$e)}else if(o)for(const f in o){const d=Et(f);if(Er(d)){const m=o[f],g=r[d]=re(m)||ue(m)?{type:m}:qe({},m),C=g.type;let k=!1,N=!0;if(re(C))for(let O=0;O<C.length;++O){const I=C[O],b=ue(I)&&I.name;if(b==="Boolean"){k=!0;break}else b==="String"&&(N=!1)}else k=ue(C)&&C.name==="Boolean";g[0]=k,g[1]=N,(k||Ce(g,"default"))&&a.push(d)}}const u=[r,a];return Le(e)&&s.set(e,u),u}function Er(e){return e[0]!=="$"&&!us(e)}const Gl=e=>e==="_"||e==="_ctx"||e==="$stable",Kl=e=>re(e)?e.map(Dt):[Dt(e)],Of=(e,t,n)=>{if(t._n)return t;const s=Ft((...l)=>Kl(t(...l)),n);return s._c=!1,s},zi=(e,t,n)=>{const s=e._ctx;for(const l in e){if(Gl(l))continue;const o=e[l];if(ue(o))t[l]=Of(l,o,s);else if(o!=null){const r=Kl(o);t[l]=()=>r}}},Qi=(e,t)=>{const n=Kl(t);e.slots.default=()=>n},Ji=(e,t,n)=>{for(const s in t)(n||!Gl(s))&&(e[s]=t[s])},Rf=(e,t,n)=>{const s=e.slots=Ki();if(e.vnode.shapeFlag&32){const l=t._;l?(Ji(s,t,n),n&&ni(s,"_",l,!0)):zi(t,s)}else t&&Qi(e,t)},Mf=(e,t,n)=>{const{vnode:s,slots:l}=e;let o=!0,r=$e;if(s.shapeFlag&32){const a=t._;a?n&&a===1?o=!1:Ji(l,t,n):(o=!t.$stable,zi(t,l)),r=t}else t&&(Qi(e,t),r={default:1});if(o)for(const a in l)!Gl(a)&&r[a]==null&&delete l[a]},bt=Jf;function Ff(e){return Uf(e)}function Uf(e,t){const n=go();n.__VUE__=!0;const{insert:s,remove:l,patchProp:o,createElement:r,createText:a,createComment:i,setText:u,setElementText:f,parentNode:d,nextSibling:m,setScopeId:g=Rt,insertStaticContent:C}=e,k=(_,w,y,R=null,j=null,W=null,z=void 0,X=null,p=!!w.dynamicChildren)=>{if(_===w)return;_&&!In(_,w)&&(R=F(_),De(_,j,W,!0),_=null),w.patchFlag===-2&&(p=!1,w.dynamicChildren=null);const{type:h,ref:D,shapeFlag:U}=w;switch(h){case Ms:N(_,w,y,R);break;case rt:O(_,w,y,R);break;case jo:_==null&&I(w,y,R,z);break;case Ge:P(_,w,y,R,j,W,z,X,p);break;default:U&1?T(_,w,y,R,j,W,z,X,p):U&6?Y(_,w,y,R,j,W,z,X,p):(U&64||U&128)&&h.process(_,w,y,R,j,W,z,X,p,ne)}D!=null&&j?ms(D,_&&_.ref,W,w||_,!w):D==null&&_&&_.ref!=null&&ms(_.ref,null,W,_,!0)},N=(_,w,y,R)=>{if(_==null)s(w.el=a(w.children),y,R);else{const j=w.el=_.el;w.children!==_.children&&u(j,w.children)}},O=(_,w,y,R)=>{_==null?s(w.el=i(w.children||""),y,R):w.el=_.el},I=(_,w,y,R)=>{[_.el,_.anchor]=C(_.children,w,y,R,_.el,_.anchor)},b=({el:_,anchor:w},y,R)=>{let j;for(;_&&_!==w;)j=m(_),s(_,y,R),_=j;s(w,y,R)},v=({el:_,anchor:w})=>{let y;for(;_&&_!==w;)y=m(_),l(_),_=y;l(w)},T=(_,w,y,R,j,W,z,X,p)=>{if(w.type==="svg"?z="svg":w.type==="math"&&(z="mathml"),_==null)$(w,y,R,j,W,z,X,p);else{const h=_.el&&_.el._isVueCE?_.el:null;try{h&&h._beginPatch(),x(_,w,j,W,z,X,p)}finally{h&&h._endPatch()}}},$=(_,w,y,R,j,W,z,X)=>{let p,h;const{props:D,shapeFlag:U,transition:J,dirs:G}=_;if(p=_.el=r(_.type,W,D&&D.is,D),U&8?f(p,_.children):U&16&&L(_.children,p,null,R,j,Wo(_,W),z,X),G&&En(_,null,R,"created"),S(p,_,_.scopeId,z,R),D){for(const V in D)V!=="value"&&!us(V)&&o(p,V,null,D[V],W,R);"value"in D&&o(p,"value",null,D.value,W),(h=D.onVnodeBeforeMount)&&Pt(h,R,_)}G&&En(_,null,R,"beforeMount");const A=Vf(j,J);A&&J.beforeEnter(p),s(p,w,y),((h=D&&D.onVnodeMounted)||A||G)&&bt(()=>{h&&Pt(h,R,_),A&&J.enter(p),G&&En(_,null,R,"mounted")},j)},S=(_,w,y,R,j)=>{if(y&&g(_,y),R)for(let W=0;W<R.length;W++)g(_,R[W]);if(j){let W=j.subTree;if(w===W||oc(W.type)&&(W.ssContent===w||W.ssFallback===w)){const z=j.vnode;S(_,z,z.scopeId,z.slotScopeIds,j.parent)}}},L=(_,w,y,R,j,W,z,X,p=0)=>{for(let h=p;h<_.length;h++){const D=_[h]=X?an(_[h]):Dt(_[h]);k(null,D,w,y,R,j,W,z,X)}},x=(_,w,y,R,j,W,z)=>{const X=w.el=_.el;let{patchFlag:p,dynamicChildren:h,dirs:D}=w;p|=_.patchFlag&16;const U=_.props||$e,J=w.props||$e;let G;if(y&&kn(y,!1),(G=J.onVnodeBeforeUpdate)&&Pt(G,y,w,_),D&&En(w,_,y,"beforeUpdate"),y&&kn(y,!0),(U.innerHTML&&J.innerHTML==null||U.textContent&&J.textContent==null)&&f(X,""),h?H(_.dynamicChildren,h,X,y,R,Wo(w,j),W):z||pe(_,w,X,null,y,R,Wo(w,j),W,!1),p>0){if(p&16)M(X,U,J,y,j);else if(p&2&&U.class!==J.class&&o(X,"class",null,J.class,j),p&4&&o(X,"style",U.style,J.style,j),p&8){const A=w.dynamicProps;for(let V=0;V<A.length;V++){const oe=A[V],ge=U[oe],Me=J[oe];(Me!==ge||oe==="value")&&o(X,oe,ge,Me,j,y)}}p&1&&_.children!==w.children&&f(X,w.children)}else!z&&h==null&&M(X,U,J,y,j);((G=J.onVnodeUpdated)||D)&&bt(()=>{G&&Pt(G,y,w,_),D&&En(w,_,y,"updated")},R)},H=(_,w,y,R,j,W,z)=>{for(let X=0;X<w.length;X++){const p=_[X],h=w[X],D=p.el&&(p.type===Ge||!In(p,h)||p.shapeFlag&198)?d(p.el):y;k(p,h,D,null,R,j,W,z,!0)}},M=(_,w,y,R,j)=>{if(w!==y){if(w!==$e)for(const W in w)!us(W)&&!(W in y)&&o(_,W,w[W],null,j,R);for(const W in y){if(us(W))continue;const z=y[W],X=w[W];z!==X&&W!=="value"&&o(_,W,X,z,j,R)}"value"in y&&o(_,"value",w.value,y.value,j)}},P=(_,w,y,R,j,W,z,X,p)=>{const h=w.el=_?_.el:a(""),D=w.anchor=_?_.anchor:a("");let{patchFlag:U,dynamicChildren:J,slotScopeIds:G}=w;G&&(X=X?X.concat(G):G),_==null?(s(h,y,R),s(D,y,R),L(w.children||[],y,D,j,W,z,X,p)):U>0&&U&64&&J&&_.dynamicChildren?(H(_.dynamicChildren,J,y,j,W,z,X),(w.key!=null||j&&w===j.subTree)&&Zi(_,w,!0)):pe(_,w,y,D,j,W,z,X,p)},Y=(_,w,y,R,j,W,z,X,p)=>{w.slotScopeIds=X,_==null?w.shapeFlag&512?j.ctx.activate(w,y,R,z,p):Se(w,y,R,j,W,z,p):Re(_,w,p)},Se=(_,w,y,R,j,W,z)=>{const X=_.component=ld(_,R,j);if(yo(_)&&(X.ctx.renderer=ne),rd(X,!1,z),X.asyncDep){if(j&&j.registerDep(X,de,z),!_.el){const p=X.subTree=ye(rt);O(null,p,w,y),_.placeholder=p.el}}else de(X,_,w,y,j,W,z)},Re=(_,w,y)=>{const R=w.component=_.component;if(zf(_,w,y))if(R.asyncDep&&!R.asyncResolved){ae(R,w,y);return}else R.next=w,R.update();else w.el=_.el,R.vnode=w},de=(_,w,y,R,j,W,z)=>{const X=()=>{if(_.isMounted){let{next:U,bu:J,u:G,parent:A,vnode:V}=_;{const ze=ec(_);if(ze){U&&(U.el=V.el,ae(_,U,z)),ze.asyncDep.then(()=>{_.isUnmounted||X()});return}}let oe=U,ge;kn(_,!1),U?(U.el=V.el,ae(_,U,z)):U=V,J&&qs(J),(ge=U.props&&U.props.onVnodeBeforeUpdate)&&Pt(ge,A,U,V),kn(_,!0);const Me=Cr(_),it=_.subTree;_.subTree=Me,k(it,Me,d(it.el),F(it),_,j,W),U.el=Me.el,oe===null&&Qf(_,Me.el),G&&bt(G,j),(ge=U.props&&U.props.onVnodeUpdated)&&bt(()=>Pt(ge,A,U,V),j)}else{let U;const{el:J,props:G}=w,{bm:A,m:V,parent:oe,root:ge,type:Me}=_,it=Xn(w);kn(_,!1),A&&qs(A),!it&&(U=G&&G.onVnodeBeforeMount)&&Pt(U,oe,w),kn(_,!0);{ge.ce&&ge.ce._def.shadowRoot!==!1&&ge.ce._injectChildStyle(Me);const ze=_.subTree=Cr(_);k(null,ze,y,R,_,j,W),w.el=ze.el}if(V&&bt(V,j),!it&&(U=G&&G.onVnodeMounted)){const ze=w;bt(()=>Pt(U,oe,ze),j)}(w.shapeFlag&256||oe&&Xn(oe.vnode)&&oe.vnode.shapeFlag&256)&&_.a&&bt(_.a,j),_.isMounted=!0,w=y=R=null}};_.scope.on();const p=_.effect=new ii(X);_.scope.off();const h=_.update=p.run.bind(p),D=_.job=p.runIfDirty.bind(p);D.i=_,D.id=_.uid,p.scheduler=()=>Bl(D),kn(_,!0),h()},ae=(_,w,y)=>{w.component=_;const R=_.vnode.props;_.vnode=w,_.next=null,Af(_,w.props,R,y),Mf(_,w.children,y),Zt(),hr(_),en()},pe=(_,w,y,R,j,W,z,X,p=!1)=>{const h=_&&_.children,D=_?_.shapeFlag:0,U=w.children,{patchFlag:J,shapeFlag:G}=w;if(J>0){if(J&128){tt(h,U,y,R,j,W,z,X,p);return}else if(J&256){Xe(h,U,y,R,j,W,z,X,p);return}}G&8?(D&16&&ve(h,j,W),U!==h&&f(y,U)):D&16?G&16?tt(h,U,y,R,j,W,z,X,p):ve(h,j,W,!0):(D&8&&f(y,""),G&16&&L(U,y,R,j,W,z,X,p))},Xe=(_,w,y,R,j,W,z,X,p)=>{_=_||Kn,w=w||Kn;const h=_.length,D=w.length,U=Math.min(h,D);let J;for(J=0;J<U;J++){const G=w[J]=p?an(w[J]):Dt(w[J]);k(_[J],G,y,null,j,W,z,X,p)}h>D?ve(_,j,W,!0,!1,U):L(w,y,R,j,W,z,X,p,U)},tt=(_,w,y,R,j,W,z,X,p)=>{let h=0;const D=w.length;let U=_.length-1,J=D-1;for(;h<=U&&h<=J;){const G=_[h],A=w[h]=p?an(w[h]):Dt(w[h]);if(In(G,A))k(G,A,y,null,j,W,z,X,p);else break;h++}for(;h<=U&&h<=J;){const G=_[U],A=w[J]=p?an(w[J]):Dt(w[J]);if(In(G,A))k(G,A,y,null,j,W,z,X,p);else break;U--,J--}if(h>U){if(h<=J){const G=J+1,A=G<D?w[G].el:R;for(;h<=J;)k(null,w[h]=p?an(w[h]):Dt(w[h]),y,A,j,W,z,X,p),h++}}else if(h>J)for(;h<=U;)De(_[h],j,W,!0),h++;else{const G=h,A=h,V=new Map;for(h=A;h<=J;h++){const vt=w[h]=p?an(w[h]):Dt(w[h]);vt.key!=null&&V.set(vt.key,h)}let oe,ge=0;const Me=J-A+1;let it=!1,ze=0;const xn=new Array(Me);for(h=0;h<Me;h++)xn[h]=0;for(h=G;h<=U;h++){const vt=_[h];if(ge>=Me){De(vt,j,W,!0);continue}let It;if(vt.key!=null)It=V.get(vt.key);else for(oe=A;oe<=J;oe++)if(xn[oe-A]===0&&In(vt,w[oe])){It=oe;break}It===void 0?De(vt,j,W,!0):(xn[It-A]=h+1,It>=ze?ze=It:it=!0,k(vt,w[It],y,null,j,W,z,X,p),ge++)}const Do=it?Hf(xn):Kn;for(oe=Do.length-1,h=Me-1;h>=0;h--){const vt=A+h,It=w[vt],cr=w[vt+1],ur=vt+1<D?cr.el||cr.placeholder:R;xn[h]===0?k(null,It,y,ur,j,W,z,X,p):it&&(oe<0||h!==Do[oe]?Ae(It,y,ur,2):oe--)}}},Ae=(_,w,y,R,j=null)=>{const{el:W,type:z,transition:X,children:p,shapeFlag:h}=_;if(h&6){Ae(_.component.subTree,w,y,R);return}if(h&128){_.suspense.move(w,y,R);return}if(h&64){z.move(_,w,y,ne);return}if(z===Ge){s(W,w,y);for(let U=0;U<p.length;U++)Ae(p[U],w,y,R);s(_.anchor,w,y);return}if(z===jo){b(_,w,y);return}if(R!==2&&h&1&&X)if(R===0)X.beforeEnter(W),s(W,w,y),bt(()=>X.enter(W),j);else{const{leave:U,delayLeave:J,afterLeave:G}=X,A=()=>{_.ctx.isUnmounted?l(W):s(W,w,y)},V=()=>{W._isLeaving&&W[Yt](!0),U(W,()=>{A(),G&&G()})};J?J(W,A,V):V()}else s(W,w,y)},De=(_,w,y,R=!1,j=!1)=>{const{type:W,props:z,ref:X,children:p,dynamicChildren:h,shapeFlag:D,patchFlag:U,dirs:J,cacheIndex:G}=_;if(U===-2&&(j=!1),X!=null&&(Zt(),ms(X,null,y,_,!0),en()),G!=null&&(w.renderCache[G]=void 0),D&256){w.ctx.deactivate(_);return}const A=D&1&&J,V=!Xn(_);let oe;if(V&&(oe=z&&z.onVnodeBeforeUnmount)&&Pt(oe,w,_),D&6)le(_.component,y,R);else{if(D&128){_.suspense.unmount(y,R);return}A&&En(_,null,w,"beforeUnmount"),D&64?_.type.remove(_,w,y,ne,R):h&&!h.hasOnce&&(W!==Ge||U>0&&U&64)?ve(h,w,y,!1,!0):(W===Ge&&U&384||!j&&D&16)&&ve(p,w,y),R&&pt(_)}(V&&(oe=z&&z.onVnodeUnmounted)||A)&&bt(()=>{oe&&Pt(oe,w,_),A&&En(_,null,w,"unmounted")},y)},pt=_=>{const{type:w,el:y,anchor:R,transition:j}=_;if(w===Ge){B(y,R);return}if(w===jo){v(_);return}const W=()=>{l(y),j&&!j.persisted&&j.afterLeave&&j.afterLeave()};if(_.shapeFlag&1&&j&&!j.persisted){const{leave:z,delayLeave:X}=j,p=()=>z(y,W);X?X(_.el,W,p):p()}else W()},B=(_,w)=>{let y;for(;_!==w;)y=m(_),l(_),_=y;l(w)},le=(_,w,y)=>{const{bum:R,scope:j,job:W,subTree:z,um:X,m:p,a:h}=_;kr(p),kr(h),R&&qs(R),j.stop(),W&&(W.flags|=8,De(z,_,w,y)),X&&bt(X,w),bt(()=>{_.isUnmounted=!0},w)},ve=(_,w,y,R=!1,j=!1,W=0)=>{for(let z=W;z<_.length;z++)De(_[z],w,y,R,j)},F=_=>{if(_.shapeFlag&6)return F(_.component.subTree);if(_.shapeFlag&128)return _.suspense.next();const w=m(_.anchor||_.el),y=w&&w[lf];return y?m(y):w};let ee=!1;const Q=(_,w,y)=>{_==null?w._vnode&&De(w._vnode,null,null,!0):k(w._vnode||null,_,w,null,null,null,y),w._vnode=_,ee||(ee=!0,hr(),Ti(),ee=!1)},ne={p:k,um:De,m:Ae,r:pt,mt:Se,mc:L,pc:pe,pbc:H,n:F,o:e};return{render:Q,hydrate:void 0,createApp:Nf(Q)}}function Wo({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function kn({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Vf(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Zi(e,t,n=!1){const s=e.children,l=t.children;if(re(s)&&re(l))for(let o=0;o<s.length;o++){const r=s[o];let a=l[o];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=l[o]=an(l[o]),a.el=r.el),!n&&a.patchFlag!==-2&&Zi(r,a)),a.type===Ms&&a.patchFlag!==-1&&(a.el=r.el),a.type===rt&&!a.el&&(a.el=r.el)}}function Hf(e){const t=e.slice(),n=[0];let s,l,o,r,a;const i=e.length;for(s=0;s<i;s++){const u=e[s];if(u!==0){if(l=n[n.length-1],e[l]<u){t[s]=l,n.push(s);continue}for(o=0,r=n.length-1;o<r;)a=o+r>>1,e[n[a]]<u?o=a+1:r=a;u<e[n[o]]&&(o>0&&(t[s]=n[o-1]),n[o]=s)}}for(o=n.length,r=n[o-1];o-- >0;)n[o]=r,r=t[r];return n}function ec(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:ec(t)}function kr(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const Wf=Symbol.for("v-scx"),jf=()=>gt(Wf);function mt(e,t,n){return tc(e,t,n)}function tc(e,t,n=$e){const{immediate:s,deep:l,flush:o,once:r}=n,a=qe({},n),i=t&&s||!t&&o!=="post";let u;if(Cs){if(o==="sync"){const g=jf();u=g.__watcherHandles||(g.__watcherHandles=[])}else if(!i){const g=()=>{};return g.stop=Rt,g.resume=Rt,g.pause=Rt,g}}const f=at;a.call=(g,C,k)=>$t(g,f,C,k);let d=!1;o==="post"?a.scheduler=g=>{bt(g,f&&f.suspense)}:o!=="sync"&&(d=!0,a.scheduler=(g,C)=>{C?g():Bl(g)}),a.augmentJob=g=>{t&&(g.flags|=4),d&&(g.flags|=2,f&&(g.id=f.uid,g.i=f))};const m=tf(e,t,a);return Cs&&(u?u.push(m):i&&m()),m}function Bf(e,t,n){const s=this.proxy,l=We(e)?e.includes(".")?nc(s,e):()=>s[e]:e.bind(s,s);let o;ue(t)?o=t:(o=t.handler,n=t);const r=Fs(this),a=tc(l,o.bind(s),n);return r(),a}function nc(e,t){const n=t.split(".");return()=>{let s=e;for(let l=0;l<n.length&&s;l++)s=s[n[l]];return s}}const Gf=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Et(t)}Modifiers`]||e[`${bn(t)}Modifiers`];function Kf(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||$e;let l=n;const o=t.startsWith("update:"),r=o&&Gf(s,t.slice(7));r&&(r.trim&&(l=n.map(f=>We(f)?f.trim():f)),r.number&&(l=n.map(ho)));let a,i=s[a=Oo(t)]||s[a=Oo(Et(t))];!i&&o&&(i=s[a=Oo(bn(t))]),i&&$t(i,e,6,l);const u=s[a+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[a])return;e.emitted[a]=!0,$t(u,e,6,l)}}const Yf=new WeakMap;function sc(e,t,n=!1){const s=n?Yf:t.emitsCache,l=s.get(e);if(l!==void 0)return l;const o=e.emits;let r={},a=!1;if(!ue(e)){const i=u=>{const f=sc(u,t,!0);f&&(a=!0,qe(r,f))};!n&&t.mixins.length&&t.mixins.forEach(i),e.extends&&i(e.extends),e.mixins&&e.mixins.forEach(i)}return!o&&!a?(Le(e)&&s.set(e,null),null):(re(o)?o.forEach(i=>r[i]=null):qe(r,o),Le(e)&&s.set(e,r),r)}function Eo(e,t){return!e||!fo(t)?!1:(t=t.slice(2).replace(/Once$/,""),Ce(e,t[0].toLowerCase()+t.slice(1))||Ce(e,bn(t))||Ce(e,t))}function Cr(e){const{type:t,vnode:n,proxy:s,withProxy:l,propsOptions:[o],slots:r,attrs:a,emit:i,render:u,renderCache:f,props:d,data:m,setupState:g,ctx:C,inheritAttrs:k}=e,N=no(e);let O,I;try{if(n.shapeFlag&4){const v=l||s,T=v;O=Dt(u.call(T,v,f,d,g,m,C)),I=a}else{const v=t;O=Dt(v.length>1?v(d,{attrs:a,slots:r,emit:i}):v(d,null)),I=t.props?a:qf(a)}}catch(v){gs.length=0,_o(v,e,1),O=ye(rt)}let b=O;if(I&&k!==!1){const v=Object.keys(I),{shapeFlag:T}=b;v.length&&T&7&&(o&&v.some(Nl)&&(I=Xf(I,o)),b=pn(b,I,!1,!0))}return n.dirs&&(b=pn(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&xs(b,n.transition),O=b,no(N),O}const qf=e=>{let t;for(const n in e)(n==="class"||n==="style"||fo(n))&&((t||(t={}))[n]=e[n]);return t},Xf=(e,t)=>{const n={};for(const s in e)(!Nl(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function zf(e,t,n){const{props:s,children:l,component:o}=e,{props:r,children:a,patchFlag:i}=t,u=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&i>=0){if(i&1024)return!0;if(i&16)return s?Sr(s,r,u):!!r;if(i&8){const f=t.dynamicProps;for(let d=0;d<f.length;d++){const m=f[d];if(r[m]!==s[m]&&!Eo(u,m))return!0}}}else return(l||a)&&(!a||!a.$stable)?!0:s===r?!1:s?r?Sr(s,r,u):!0:!!r;return!1}function Sr(e,t,n){const s=Object.keys(t);if(s.length!==Object.keys(e).length)return!0;for(let l=0;l<s.length;l++){const o=s[l];if(t[o]!==e[o]&&!Eo(n,o))return!0}return!1}function Qf({vnode:e,parent:t},n){for(;t;){const s=t.subTree;if(s.suspense&&s.suspense.activeBranch===e&&(s.el=e.el),s===e)(e=t.vnode).el=n,t=t.parent;else break}}const oc=e=>e.__isSuspense;function Jf(e,t){t&&t.pendingBranch?re(e)?t.effects.push(...e):t.effects.push(e):of(e)}const Ge=Symbol.for("v-fgt"),Ms=Symbol.for("v-txt"),rt=Symbol.for("v-cmt"),jo=Symbol.for("v-stc"),gs=[];let _t=null;function K(e=!1){gs.push(_t=e?null:[])}function Zf(){gs.pop(),_t=gs[gs.length-1]||null}let Es=1;function lo(e,t=!1){Es+=e,e<0&&_t&&t&&(_t.hasOnce=!0)}function lc(e){return e.dynamicChildren=Es>0?_t||Kn:null,Zf(),Es>0&&_t&&_t.push(e),e}function Z(e,t,n,s,l,o){return lc(c(e,t,n,s,l,o,!0))}function Ut(e,t,n,s,l){return lc(ye(e,t,n,s,l,!0))}function ks(e){return e?e.__v_isVNode===!0:!1}function In(e,t){return e.type===t.type&&e.key===t.key}const rc=({key:e})=>e??null,Xs=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?We(e)||Ve(e)||ue(e)?{i:Ze,r:e,k:t,f:!!n}:e:null);function c(e,t=null,n=null,s=0,l=null,o=e===Ge?0:1,r=!1,a=!1){const i={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&rc(t),ref:t&&Xs(t),scopeId:$i,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:o,patchFlag:s,dynamicProps:l,dynamicChildren:null,appContext:null,ctx:Ze};return a?(Yl(i,n),o&128&&e.normalize(i)):n&&(i.shapeFlag|=We(n)?8:16),Es>0&&!r&&_t&&(i.patchFlag>0||o&6)&&i.patchFlag!==32&&_t.push(i),i}const ye=ed;function ed(e,t=null,n=null,s=0,l=null,o=!1){if((!e||e===wf)&&(e=rt),ks(e)){const a=pn(e,t,!0);return n&&Yl(a,n),Es>0&&!o&&_t&&(a.shapeFlag&6?_t[_t.indexOf(e)]=a:_t.push(a)),a.patchFlag=-2,a}if(fd(e)&&(e=e.__vccOpts),t){t=td(t);let{class:a,style:i}=t;a&&!We(a)&&(t.class=Qe(a)),Le(i)&&(Hl(i)&&!re(i)&&(i=qe({},i)),t.style=vo(i))}const r=We(e)?1:oc(e)?128:Ni(e)?64:Le(e)?4:ue(e)?2:0;return c(e,t,n,s,l,r,o,!0)}function td(e){return e?Hl(e)||Yi(e)?qe({},e):e:null}function pn(e,t,n=!1,s=!1){const{props:l,ref:o,patchFlag:r,children:a,transition:i}=e,u=t?nd(l||{},t):l,f={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&rc(u),ref:t&&t.ref?n&&o?re(o)?o.concat(Xs(t)):[o,Xs(t)]:Xs(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Ge?r===-1?16:r|16:r,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:i,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&pn(e.ssContent),ssFallback:e.ssFallback&&pn(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return i&&s&&xs(f,i.clone(f)),f}function _e(e=" ",t=0){return ye(Ms,null,e,t)}function se(e="",t=!1){return t?(K(),Ut(rt,null,e)):ye(rt,null,e)}function Dt(e){return e==null||typeof e=="boolean"?ye(rt):re(e)?ye(Ge,null,e.slice()):ks(e)?an(e):ye(Ms,null,String(e))}function an(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:pn(e)}function Yl(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(re(t))n=16;else if(typeof t=="object")if(s&65){const l=t.default;l&&(l._c&&(l._d=!1),Yl(e,l()),l._c&&(l._d=!0));return}else{n=32;const l=t._;!l&&!Yi(t)?t._ctx=Ze:l===3&&Ze&&(Ze.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else ue(t)?(t={default:t,_ctx:Ze},n=32):(t=String(t),s&64?(n=16,t=[_e(t)]):n=8);e.children=t,e.shapeFlag|=n}function nd(...e){const t={};for(let n=0;n<e.length;n++){const s=e[n];for(const l in s)if(l==="class")t.class!==s.class&&(t.class=Qe([t.class,s.class]));else if(l==="style")t.style=vo([t.style,s.style]);else if(fo(l)){const o=t[l],r=s[l];r&&o!==r&&!(re(o)&&o.includes(r))&&(t[l]=o?[].concat(o,r):r)}else l!==""&&(t[l]=s[l])}return t}function Pt(e,t,n,s=null){$t(e,t,7,[n,s])}const sd=Bi();let od=0;function ld(e,t,n){const s=e.type,l=(t?t.appContext:e.appContext)||sd,o={uid:od++,vnode:e,type:s,parent:t,appContext:l,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new ri(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(l.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Xi(s,l),emitsOptions:sc(s,l),emit:null,emitted:null,propsDefaults:$e,inheritAttrs:s.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 o.ctx={_:o},o.root=t?t.root:o,o.emit=Kf.bind(null,o),e.ce&&e.ce(o),o}let at=null;const hn=()=>at||Ze;let ro,ul;{const e=go(),t=(n,s)=>{let l;return(l=e[n])||(l=e[n]=[]),l.push(s),o=>{l.length>1?l.forEach(r=>r(o)):l[0](o)}};ro=t("__VUE_INSTANCE_SETTERS__",n=>at=n),ul=t("__VUE_SSR_SETTERS__",n=>Cs=n)}const Fs=e=>{const t=at;return ro(e),e.scope.on(),()=>{e.scope.off(),ro(t)}},Tr=()=>{at&&at.scope.off(),ro(null)};function ac(e){return e.vnode.shapeFlag&4}let Cs=!1;function rd(e,t=!1,n=!1){t&&ul(t);const{props:s,children:l}=e.vnode,o=ac(e);Pf(e,s,o,t),Rf(e,l,n||t);const r=o?ad(e,t):void 0;return t&&ul(!1),r}function ad(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Ef);const{setup:s}=n;if(s){Zt();const l=e.setupContext=s.length>1?cd(e):null,o=Fs(e),r=Os(s,e,0,[e.props,l]),a=Za(r);if(en(),o(),(a||e.sp)&&!Xn(e)&&Ri(e),a){if(r.then(Tr,Tr),t)return r.then(i=>{Lr(e,i)}).catch(i=>{_o(i,e,0)});e.asyncDep=r}else Lr(e,r)}else ic(e)}function Lr(e,t,n){ue(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Le(t)&&(e.setupState=ki(t)),ic(e)}function ic(e,t,n){const s=e.type;e.render||(e.render=s.render||Rt);{const l=Fs(e);Zt();try{kf(e)}finally{en(),l()}}}const id={get(e,t){return lt(e,"get",""),e[t]}};function cd(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,id),slots:e.slots,emit:e.emit,expose:t}}function ko(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(ki(Wl(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in ps)return ps[n](e)},has(t,n){return n in t||n in ps}})):e.proxy}function ud(e,t=!0){return ue(e)?e.displayName||e.name:e.name||t&&e.__name}function fd(e){return ue(e)&&"__vccOpts"in e}const fe=(e,t)=>Zu(e,t,Cs);function Us(e,t,n){try{lo(-1);const s=arguments.length;return s===2?Le(t)&&!re(t)?ks(t)?ye(e,null,[t]):ye(e,t):ye(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&ks(n)&&(n=[n]),ye(e,t,n))}finally{lo(1)}}const dd="3.5.24";let fl;const $r=typeof window<"u"&&window.trustedTypes;if($r)try{fl=$r.createPolicy("vue",{createHTML:e=>e})}catch{}const cc=fl?e=>fl.createHTML(e):e=>e,md="http://www.w3.org/2000/svg",pd="http://www.w3.org/1998/Math/MathML",Kt=typeof document<"u"?document:null,Nr=Kt&&Kt.createElement("template"),hd={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const l=t==="svg"?Kt.createElementNS(md,e):t==="mathml"?Kt.createElementNS(pd,e):n?Kt.createElement(e,{is:n}):Kt.createElement(e);return e==="select"&&s&&s.multiple!=null&&l.setAttribute("multiple",s.multiple),l},createText:e=>Kt.createTextNode(e),createComment:e=>Kt.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Kt.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,l,o){const r=n?n.previousSibling:t.lastChild;if(l&&(l===o||l.nextSibling))for(;t.insertBefore(l.cloneNode(!0),n),!(l===o||!(l=l.nextSibling)););else{Nr.innerHTML=cc(s==="svg"?`<svg>${e}</svg>`:s==="mathml"?`<math>${e}</math>`:e);const a=Nr.content;if(s==="svg"||s==="mathml"){const i=a.firstChild;for(;i.firstChild;)a.appendChild(i.firstChild);a.removeChild(i)}t.insertBefore(a,n)}return[r?r.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},nn="transition",rs="animation",Ss=Symbol("_vtc"),uc={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},gd=qe({},Ii,uc),vd=e=>(e.displayName="Transition",e.props=gd,e),Ir=vd((e,{slots:t})=>Us(cf,bd(e),t)),Cn=(e,t=[])=>{re(e)?e.forEach(n=>n(...t)):e&&e(...t)},Pr=e=>e?re(e)?e.some(t=>t.length>1):e.length>1:!1;function bd(e){const t={};for(const P in e)P in uc||(t[P]=e[P]);if(e.css===!1)return t;const{name:n="v",type:s,duration:l,enterFromClass:o=`${n}-enter-from`,enterActiveClass:r=`${n}-enter-active`,enterToClass:a=`${n}-enter-to`,appearFromClass:i=o,appearActiveClass:u=r,appearToClass:f=a,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:m=`${n}-leave-active`,leaveToClass:g=`${n}-leave-to`}=e,C=_d(l),k=C&&C[0],N=C&&C[1],{onBeforeEnter:O,onEnter:I,onEnterCancelled:b,onLeave:v,onLeaveCancelled:T,onBeforeAppear:$=O,onAppear:S=I,onAppearCancelled:L=b}=t,x=(P,Y,Se,Re)=>{P._enterCancelled=Re,Sn(P,Y?f:a),Sn(P,Y?u:r),Se&&Se()},H=(P,Y)=>{P._isLeaving=!1,Sn(P,d),Sn(P,g),Sn(P,m),Y&&Y()},M=P=>(Y,Se)=>{const Re=P?S:I,de=()=>x(Y,P,Se);Cn(Re,[Y,de]),Ar(()=>{Sn(Y,P?i:o),Wt(Y,P?f:a),Pr(Re)||Dr(Y,s,k,de)})};return qe(t,{onBeforeEnter(P){Cn(O,[P]),Wt(P,o),Wt(P,r)},onBeforeAppear(P){Cn($,[P]),Wt(P,i),Wt(P,u)},onEnter:M(!1),onAppear:M(!0),onLeave(P,Y){P._isLeaving=!0;const Se=()=>H(P,Y);Wt(P,d),P._enterCancelled?(Wt(P,m),Mr(P)):(Mr(P),Wt(P,m)),Ar(()=>{P._isLeaving&&(Sn(P,d),Wt(P,g),Pr(v)||Dr(P,s,N,Se))}),Cn(v,[P,Se])},onEnterCancelled(P){x(P,!1,void 0,!0),Cn(b,[P])},onAppearCancelled(P){x(P,!0,void 0,!0),Cn(L,[P])},onLeaveCancelled(P){H(P),Cn(T,[P])}})}function _d(e){if(e==null)return null;if(Le(e))return[Bo(e.enter),Bo(e.leave)];{const t=Bo(e);return[t,t]}}function Bo(e){return _u(e)}function Wt(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Ss]||(e[Ss]=new Set)).add(t)}function Sn(e,t){t.split(/\s+/).forEach(s=>s&&e.classList.remove(s));const n=e[Ss];n&&(n.delete(t),n.size||(e[Ss]=void 0))}function Ar(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let yd=0;function Dr(e,t,n,s){const l=e._endId=++yd,o=()=>{l===e._endId&&s()};if(n!=null)return setTimeout(o,n);const{type:r,timeout:a,propCount:i}=wd(e,t);if(!r)return s();const u=r+"end";let f=0;const d=()=>{e.removeEventListener(u,m),o()},m=g=>{g.target===e&&++f>=i&&d()};setTimeout(()=>{f<i&&d()},a+1),e.addEventListener(u,m)}function wd(e,t){const n=window.getComputedStyle(e),s=C=>(n[C]||"").split(", "),l=s(`${nn}Delay`),o=s(`${nn}Duration`),r=Or(l,o),a=s(`${rs}Delay`),i=s(`${rs}Duration`),u=Or(a,i);let f=null,d=0,m=0;t===nn?r>0&&(f=nn,d=r,m=o.length):t===rs?u>0&&(f=rs,d=u,m=i.length):(d=Math.max(r,u),f=d>0?r>u?nn:rs:null,m=f?f===nn?o.length:i.length:0);const g=f===nn&&/\b(?:transform|all)(?:,|$)/.test(s(`${nn}Property`).toString());return{type:f,timeout:d,propCount:m,hasTransform:g}}function Or(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,s)=>Rr(n)+Rr(e[s])))}function Rr(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function Mr(e){return(e?e.ownerDocument:document).body.offsetHeight}function xd(e,t,n){const s=e[Ss];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Fr=Symbol("_vod"),Ed=Symbol("_vsh"),kd=Symbol(""),Cd=/(?:^|;)\s*display\s*:/;function Sd(e,t,n){const s=e.style,l=We(n);let o=!1;if(n&&!l){if(t)if(We(t))for(const r of t.split(";")){const a=r.slice(0,r.indexOf(":")).trim();n[a]==null&&zs(s,a,"")}else for(const r in t)n[r]==null&&zs(s,r,"");for(const r in n)r==="display"&&(o=!0),zs(s,r,n[r])}else if(l){if(t!==n){const r=s[kd];r&&(n+=";"+r),s.cssText=n,o=Cd.test(n)}}else t&&e.removeAttribute("style");Fr in e&&(e[Fr]=o?s.display:"",e[Ed]&&(s.display="none"))}const Ur=/\s*!important$/;function zs(e,t,n){if(re(n))n.forEach(s=>zs(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=Td(e,t);Ur.test(n)?e.setProperty(bn(s),n.replace(Ur,""),"important"):e[s]=n}}const Vr=["Webkit","Moz","ms"],Go={};function Td(e,t){const n=Go[t];if(n)return n;let s=Et(t);if(s!=="filter"&&s in e)return Go[t]=s;s=po(s);for(let l=0;l<Vr.length;l++){const o=Vr[l]+s;if(o in e)return Go[t]=o}return t}const Hr="http://www.w3.org/1999/xlink";function Wr(e,t,n,s,l,o=Cu(t)){s&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(Hr,t.slice(6,t.length)):e.setAttributeNS(Hr,t,n):n==null||o&&!si(n)?e.removeAttribute(t):e.setAttribute(t,o?"":Lt(n)?String(n):n)}function jr(e,t,n,s,l){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?cc(n):n);return}const o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){const a=o==="OPTION"?e.getAttribute("value")||"":e.value,i=n==null?e.type==="checkbox"?"on":"":String(n);(a!==i||!("_value"in e))&&(e.value=i),n==null&&e.removeAttribute(t),e._value=n;return}let r=!1;if(n===""||n==null){const a=typeof e[t];a==="boolean"?n=si(n):n==null&&a==="string"?(n="",r=!0):a==="number"&&(n=0,r=!0)}try{e[t]=n}catch{}r&&e.removeAttribute(l||t)}function un(e,t,n,s){e.addEventListener(t,n,s)}function Ld(e,t,n,s){e.removeEventListener(t,n,s)}const Br=Symbol("_vei");function $d(e,t,n,s,l=null){const o=e[Br]||(e[Br]={}),r=o[t];if(s&&r)r.value=s;else{const[a,i]=Nd(t);if(s){const u=o[t]=Ad(s,l);un(e,a,u,i)}else r&&(Ld(e,a,r,i),o[t]=void 0)}}const Gr=/(?:Once|Passive|Capture)$/;function Nd(e){let t;if(Gr.test(e)){t={};let s;for(;s=e.match(Gr);)e=e.slice(0,e.length-s[0].length),t[s[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):bn(e.slice(2)),t]}let Ko=0;const Id=Promise.resolve(),Pd=()=>Ko||(Id.then(()=>Ko=0),Ko=Date.now());function Ad(e,t){const n=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=n.attached)return;$t(Dd(s,n.value),t,5,[s])};return n.value=e,n.attached=Pd(),n}function Dd(e,t){if(re(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(s=>l=>!l._stopped&&s&&s(l))}else return t}const Kr=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Od=(e,t,n,s,l,o)=>{const r=l==="svg";t==="class"?xd(e,s,r):t==="style"?Sd(e,n,s):fo(t)?Nl(t)||$d(e,t,n,s,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Rd(e,t,s,r))?(jr(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Wr(e,t,s,r,o,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!We(s))?jr(e,Et(t),s,o,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),Wr(e,t,s,r))};function Rd(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&Kr(t)&&ue(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const l=e.tagName;if(l==="IMG"||l==="VIDEO"||l==="CANVAS"||l==="SOURCE")return!1}return Kr(t)&&We(n)?!1:t in e}const zn=e=>{const t=e.props["onUpdate:modelValue"]||!1;return re(t)?n=>qs(t,n):t};function Md(e){e.target.composing=!0}function Yr(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Qt=Symbol("_assign");function qr(e,t,n){return t&&(e=e.trim()),n&&(e=ho(e)),e}const ot={created(e,{modifiers:{lazy:t,trim:n,number:s}},l){e[Qt]=zn(l);const o=s||l.props&&l.props.type==="number";un(e,t?"change":"input",r=>{r.target.composing||e[Qt](qr(e.value,n,o))}),(n||o)&&un(e,"change",()=>{e.value=qr(e.value,n,o)}),t||(un(e,"compositionstart",Md),un(e,"compositionend",Yr),un(e,"change",Yr))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:s,trim:l,number:o}},r){if(e[Qt]=zn(r),e.composing)return;const a=(o||e.type==="number")&&!/^0\d/.test(e.value)?ho(e.value):e.value,i=t??"";a!==i&&(document.activeElement===e&&e.type!=="range"&&(s&&t===n||l&&e.value.trim()===i)||(e.value=i))}},Bn={deep:!0,created(e,t,n){e[Qt]=zn(n),un(e,"change",()=>{const s=e._modelValue,l=Ts(e),o=e.checked,r=e[Qt];if(re(s)){const a=Al(s,l),i=a!==-1;if(o&&!i)r(s.concat(l));else if(!o&&i){const u=[...s];u.splice(a,1),r(u)}}else if(ns(s)){const a=new Set(s);o?a.add(l):a.delete(l),r(a)}else r(fc(e,o))})},mounted:Xr,beforeUpdate(e,t,n){e[Qt]=zn(n),Xr(e,t,n)}};function Xr(e,{value:t,oldValue:n},s){e._modelValue=t;let l;if(re(t))l=Al(t,s.props.value)>-1;else if(ns(t))l=t.has(s.props.value);else{if(t===n)return;l=As(t,fc(e,!0))}e.checked!==l&&(e.checked=l)}const Fd={deep:!0,created(e,{value:t,modifiers:{number:n}},s){const l=ns(t);un(e,"change",()=>{const o=Array.prototype.filter.call(e.options,r=>r.selected).map(r=>n?ho(Ts(r)):Ts(r));e[Qt](e.multiple?l?new Set(o):o:o[0]),e._assigning=!0,Rs(()=>{e._assigning=!1})}),e[Qt]=zn(s)},mounted(e,{value:t}){zr(e,t)},beforeUpdate(e,t,n){e[Qt]=zn(n)},updated(e,{value:t}){e._assigning||zr(e,t)}};function zr(e,t){const n=e.multiple,s=re(t);if(!(n&&!s&&!ns(t))){for(let l=0,o=e.options.length;l<o;l++){const r=e.options[l],a=Ts(r);if(n)if(s){const i=typeof a;i==="string"||i==="number"?r.selected=t.some(u=>String(u)===String(a)):r.selected=Al(t,a)>-1}else r.selected=t.has(a);else if(As(Ts(r),t)){e.selectedIndex!==l&&(e.selectedIndex=l);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Ts(e){return"_value"in e?e._value:e.value}function fc(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Ud=["ctrl","shift","alt","meta"],Vd={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&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>Ud.some(n=>e[`${n}Key`]&&!t.includes(n))},gn=(e,t)=>{const n=e._withMods||(e._withMods={}),s=t.join(".");return n[s]||(n[s]=((l,...o)=>{for(let r=0;r<t.length;r++){const a=Vd[t[r]];if(a&&a(l,t))return}return e(l,...o)}))},Hd={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},ql=(e,t)=>{const n=e._withKeys||(e._withKeys={}),s=t.join(".");return n[s]||(n[s]=(l=>{if(!("key"in l))return;const o=bn(l.key);if(t.some(r=>r===o||Hd[r]===o))return e(l)}))},Wd=qe({patchProp:Od},hd);let Qr;function jd(){return Qr||(Qr=Ff(Wd))}const Bd=((...e)=>{const t=jd().createApp(...e),{mount:n}=t;return t.mount=s=>{const l=Kd(s);if(!l)return;const o=t._component;!ue(o)&&!o.render&&!o.template&&(o.template=l.innerHTML),l.nodeType===1&&(l.textContent="");const r=n(l,!1,Gd(l));return l instanceof Element&&(l.removeAttribute("v-cloak"),l.setAttribute("data-v-app","")),r},t});function Gd(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Kd(e){return We(e)?document.querySelector(e):e}let dc;const Co=e=>dc=e,mc=Symbol();function dl(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var vs;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(vs||(vs={}));function Yd(){const e=Dl(!0),t=e.run(()=>q({}));let n=[],s=[];const l=Wl({install(o){Co(l),l._a=o,o.provide(mc,l),o.config.globalProperties.$pinia=l,s.forEach(r=>n.push(r)),s=[]},use(o){return this._a?n.push(o):s.push(o),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return l}const pc=()=>{};function Jr(e,t,n,s=pc){e.add(t);const l=()=>{e.delete(t)&&s()};return!n&&ai()&&Tu(l),l}function Un(e,...t){e.forEach(n=>{n(...t)})}const qd=e=>e(),Zr=Symbol(),Yo=Symbol();function ml(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,s)=>e.set(s,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const s=t[n],l=e[n];dl(l)&&dl(s)&&e.hasOwnProperty(n)&&!Ve(s)&&!dn(s)?e[n]=ml(l,s):e[n]=s}return e}const Xd=Symbol();function zd(e){return!dl(e)||!Object.prototype.hasOwnProperty.call(e,Xd)}const{assign:ln}=Object;function Qd(e){return!!(Ve(e)&&e.effect)}function Jd(e,t,n,s){const{state:l,actions:o,getters:r}=t,a=n.state.value[e];let i;function u(){a||(n.state.value[e]=l?l():{});const f=Xu(n.state.value[e]);return ln(f,o,Object.keys(r||{}).reduce((d,m)=>(d[m]=Wl(fe(()=>{Co(n);const g=n._s.get(e);return r[m].call(g,g)})),d),{}))}return i=hc(e,u,t,n,s,!0),i}function hc(e,t,n={},s,l,o){let r;const a=ln({actions:{}},n),i={deep:!0};let u,f,d=new Set,m=new Set,g;const C=s.state.value[e];!o&&!C&&(s.state.value[e]={}),q({});let k;function N(L){let x;u=f=!1,typeof L=="function"?(L(s.state.value[e]),x={type:vs.patchFunction,storeId:e,events:g}):(ml(s.state.value[e],L),x={type:vs.patchObject,payload:L,storeId:e,events:g});const H=k=Symbol();Rs().then(()=>{k===H&&(u=!0)}),f=!0,Un(d,x,s.state.value[e])}const O=o?function(){const{state:x}=n,H=x?x():{};this.$patch(M=>{ln(M,H)})}:pc;function I(){r.stop(),d.clear(),m.clear(),s._s.delete(e)}const b=(L,x="")=>{if(Zr in L)return L[Yo]=x,L;const H=function(){Co(s);const M=Array.from(arguments),P=new Set,Y=new Set;function Se(ae){P.add(ae)}function Re(ae){Y.add(ae)}Un(m,{args:M,name:H[Yo],store:T,after:Se,onError:Re});let de;try{de=L.apply(this&&this.$id===e?this:T,M)}catch(ae){throw Un(Y,ae),ae}return de instanceof Promise?de.then(ae=>(Un(P,ae),ae)).catch(ae=>(Un(Y,ae),Promise.reject(ae))):(Un(P,de),de)};return H[Zr]=!0,H[Yo]=x,H},v={_p:s,$id:e,$onAction:Jr.bind(null,m),$patch:N,$reset:O,$subscribe(L,x={}){const H=Jr(d,L,x.detached,()=>M()),M=r.run(()=>mt(()=>s.state.value[e],P=>{(x.flush==="sync"?f:u)&&L({storeId:e,type:vs.direct,events:g},P)},ln({},i,x)));return H},$dispose:I},T=Ds(v);s._s.set(e,T);const S=(s._a&&s._a.runWithContext||qd)(()=>s._e.run(()=>(r=Dl()).run(()=>t({action:b}))));for(const L in S){const x=S[L];if(Ve(x)&&!Qd(x)||dn(x))o||(C&&zd(x)&&(Ve(x)?x.value=C[L]:ml(x,C[L])),s.state.value[e][L]=x);else if(typeof x=="function"){const H=b(x,L);S[L]=H,a.actions[L]=x}}return ln(T,S),ln(we(T),S),Object.defineProperty(T,"$state",{get:()=>s.state.value[e],set:L=>{N(x=>{ln(x,L)})}}),s._p.forEach(L=>{ln(T,r.run(()=>L({store:T,app:s._a,pinia:s,options:a})))}),C&&o&&n.hydrate&&n.hydrate(T.$state,C),u=!0,f=!0,T}function Xl(e,t,n){let s;const l=typeof t=="function";s=l?n:t;function o(r,a){const i=If();return r=r||(i?gt(mc,null):null),r&&Co(r),r=dc,r._s.has(e)||(l?hc(e,t,s,r):Jd(e,s,r)),r._s.get(e)}return o.$id=e,o}const Zd="";function em(e){const t={"content-type":"application/json"};return e&&(t.authorization=e),t}async function gc(e,t={}){const{method:n="GET",headers:s={},body:l}=t,o=localStorage.getItem("token")||"";try{const a=await(await fetch(`${Zd}${e}`,{method:n,headers:{...em(o),...s},body:typeof l=="string"?l:l?JSON.stringify(l):void 0})).json();return a.code&&console.error(`[${e}] 请求失败:`,a.message),a}catch(r){return console.error(`请求失败: ${e}`,r),{code:-1,message:r instanceof Error?r.message:"请求失败"}}}function vc(e){return gc(e,{method:"GET"})}function Rn(e,t){return gc(e,{method:"POST",body:t})}async function tm(){const e=await vc("/api/config");return e.code===0&&e.data?e.data:{}}async function nm(e){return Rn("/api/config",e)}async function sm(){const e=await vc("/api/tasks");return e.code===0&&e.data?e.data:{}}async function om(e){return Rn("/api/download",{list:e})}async function lm(e,t=!1){return Rn("/api/pause",{urls:e,all:t})}async function rm(e,t=!1){return Rn("/api/resume",{urls:e,all:t})}async function bc(e,t=!0,n=!0){return Rn("/api/delete",{urls:e,deleteCache:t,deleteVideo:n})}async function am(e,t,n){return Rn("/api/getM3u8Urls",{url:e,headers:t,subUrlRegex:n})}async function im(){return Rn("/api/queue/clear",{})}const ss=Xl("config",()=>{const e=q({threadNum:0,saveDir:"",delCache:!0,convert:!0,showPreview:!0,showLocalPlay:!0,maxDownloads:3,ffmpegPath:""}),t=q("");async function n(){try{const l=await tm();return l&&typeof l=="object"&&"saveDir"in l?(Object.assign(e.value,l),!0):!1}catch(l){return console.error("加载配置失败:",l),!1}}async function s(){return await nm(e.value)}return{config:e,token:t,loadConfig:n,updateConfig:s}}),zl=Xl("server",()=>{const e=q({version:"{{version}}",ariang:!1,newVersion:"",appUpdateMessage:""});function t(n){Object.assign(e.value,n)}return{serverInfo:e,updateServerInfo:t}}),Mn=Xl("tasks",()=>{const e=q({}),t=q([]),n=q({queueLength:0,activeDownloads:[],maxConcurrent:5}),s=q(""),l=q(""),o=fe(()=>{const C=Object.values(e.value);console.log("[TasksStore] filteredTasks computed, tasks.value keys:",Object.keys(e.value).length,"taskValues length:",C.length);let k=C;if(k=k.filter(I=>!(I.status==="done"||I.progress!==void 0&&I.progress>=100)),s.value){const I=s.value.toLowerCase();k=k.filter(b=>(b.localVideo||b.filename||b.dlOptions?.filename||b.url).toLowerCase().includes(I)||b.url.toLowerCase().includes(I))}l.value&&(k=k.filter(I=>I.status===l.value));const N={resume:0,pending:1,pause:2,error:3,done:4};k.sort((I,b)=>{const v=N[I.status]-N[b.status];return v!==0?v:I.status==="done"?(b.filename||"").localeCompare(I.filename||""):(I.startTime||0)-(b.startTime||0)});const O={queueLength:0,activeDownloads:[],maxConcurrent:n.value.maxConcurrent};return k.forEach(I=>{I.showName=I.filename||I.dlOptions?.filename||I.localVideo||I.url,I.status==="pending"?O.queueLength++:I.status==="resume"&&O.activeDownloads.push(I.url)}),(O.queueLength!==n.value.queueLength||O.activeDownloads.length!==n.value.activeDownloads.length)&&(n.value=O),k});function r(C){console.log("[TasksStore] setTasks 被调用,任务数量:",Object.keys(C||{}).length),C&&typeof C=="object"?(e.value=C,console.log("[TasksStore] 任务已更新,当前任务数量:",Object.keys(e.value).length)):console.warn("[TasksStore] setTasks 收到无效数据:",C)}function a(C,k){e.value[C]&&(e.value[C]={...e.value[C],...k})}function i(C){C.forEach(({url:k,data:N})=>{e.value[k]&&(e.value[k]={...e.value[k],...N})})}function u(C){C.forEach(k=>{delete e.value[k]})}function f(C){const k=t.value.indexOf(C);k===-1?t.value.push(C):t.value.splice(k,1)}function d(){const C=t.value.length===o.value.length;t.value=C?[]:o.value.map(k=>k.url)}function m(){t.value=[]}function g(){s.value="",l.value=""}return{tasks:e,selectedTasks:t,queueStatus:n,searchQuery:s,statusFilter:l,filteredTasks:o,setTasks:r,updateTask:a,updateTasks:i,deleteTasks:u,toggleTaskSelection:f,toggleSelectAll:d,clearSelection:m,clearFilters:g}}),cm={success:"fa-check-circle text-green-600",error:"fa-times-circle text-red-600",warning:"fa-exclamation-triangle text-yellow-600",info:"fa-info-circle text-blue-500"};function be(e){const t=typeof e=="string"?{text:e}:e,n=t.type||"success",s=t.duration??3e3,l=document.createElement("div");l.className=`custom-toast custom-toast-${n}`,l.innerHTML=[`<i class="custom-toast-icon mr-2 fa ${cm[n]}"></i>`,`<span class="break-all">${t.text||""}</span>`,'<i class="custom-toast-close fa fa-close fixed right-2 cursor-pointer text-lg" onclick="this.parentElement.remove()"></i>'].join(""),document.body.appendChild(l),setTimeout(()=>l.classList.add("show"),10);const o=()=>{l.classList.remove("show"),l.classList.add("hide"),setTimeout(()=>l.remove(),300)};return s>0&&setTimeout(()=>o(),s),{element:l,close:o}}let st=null,Gs=3e3,Jt=null,pl=null,Nn=null,ao="",Hn=!1;function um(e,t=!1,n){if(ao=e,Hn=t,n&&(Nn=n),st){try{st.close()}catch{}st=null}Jt&&(clearTimeout(Jt),Jt=null),Ql(ao)}function Ql(e){if(st&&st.readyState===WebSocket.OPEN)return;if(st&&st.readyState!==WebSocket.OPEN){try{st.close()}catch{}st=null}const n=`${location.protocol==="https:"?"wss":"ws"}://${location.host}/ws?token=${e}`,s=new WebSocket(n);st=s,s.onmessage=l=>{try{const{type:o,data:r}=JSON.parse(l.data),a=Mn(),i=zl();switch(o){case"serverInfo":i.updateServerInfo(r),Hn&&(be({text:"密码验证成功,连接已建立",type:"success"}),Hn=!1,Nn&&(Nn(!0),Nn=null));break;case"tasks":console.log("[WebSocket] 收到任务数据:",r),r&&typeof r=="object"&&(a.setTasks(r),console.log("[WebSocket] 任务数据已更新,任务数量:",Object.keys(r).length));break;case"progress":{(Array.isArray(r)?r:[r]).forEach(f=>{f.url&&a.updateTask(f.url,f)});break}case"delete":Array.isArray(r)&&a.deleteTasks(r);break;case"queueStatus":r&&(a.queueStatus=r);break}}catch(o){console.error("WebSocket 消息解析失败:",o)}},s.onopen=()=>{Hn||be({text:"WebSocket connected",type:"success"}),Gs=3e3},s.onclose=l=>{if(console.error("ws连接关闭:",l.code,l.reason),st=null,l.code===1008){Hn?(Hn=!1,Nn&&(Nn(!1),Nn=null)):pl&&pl();return}be({text:`Connection lost, will retry in ${Gs/1e3}s...`,type:"error"}),Jt&&clearTimeout(Jt),Jt=window.setTimeout(()=>{Gs+=1e3,Ql(ao)},Gs)},s.onerror=l=>{console.error("WebSocket 错误:",l)}}function Jl(e,t){const n=q(null);t&&(pl=t),ao=e;function s(){Ql(e),st&&(n.value=st)}function l(){Jt&&(clearTimeout(Jt),Jt=null),st&&(st.close(),st=null),n.value=null}return{ws:n,connect:s,disconnect:l}}function fm(e,t){typeof console<"u"&&(console.warn("[intlify] "+e),t&&console.warn(t.stack))}const io=typeof window<"u",_n=(e,t=!1)=>t?Symbol.for(e):Symbol(e),dm=(e,t,n)=>mm({l:e,k:t,s:n}),mm=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),He=e=>typeof e=="number"&&isFinite(e),pm=e=>yc(e)==="[object Date]",vn=e=>yc(e)==="[object RegExp]",So=e=>ce(e)&&Object.keys(e).length===0,et=Object.assign,hm=Object.create,Te=(e=null)=>hm(e);let ea;const zt=()=>ea||(ea=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:Te());function ta(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/").replace(/=/g,"=")}function na(e){return e.replace(/&(?![a-zA-Z0-9#]{2,6};)/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function gm(e){return e=e.replace(/(\w+)\s*=\s*"([^"]*)"/g,(s,l,o)=>`${l}="${na(o)}"`),e=e.replace(/(\w+)\s*=\s*'([^']*)'/g,(s,l,o)=>`${l}='${na(o)}'`),/\s*on\w+\s*=\s*["']?[^"'>]+["']?/gi.test(e)&&(e=e.replace(/(\s+)(on)(\w+\s*=)/gi,"$1on$3")),[/(\s+(?:href|src|action|formaction)\s*=\s*["']?)\s*javascript:/gi,/(style\s*=\s*["'][^"']*url\s*\(\s*)javascript:/gi].forEach(s=>{e=e.replace(s,"$1javascript:")}),e}const vm=Object.prototype.hasOwnProperty;function Ct(e,t){return vm.call(e,t)}const Pe=Array.isArray,Ie=e=>typeof e=="function",te=e=>typeof e=="string",he=e=>typeof e=="boolean",xe=e=>e!==null&&typeof e=="object",bm=e=>xe(e)&&Ie(e.then)&&Ie(e.catch),_c=Object.prototype.toString,yc=e=>_c.call(e),ce=e=>{if(!xe(e))return!1;const t=Object.getPrototypeOf(e);return t===null||t.constructor===Object},_m=e=>e==null?"":Pe(e)||ce(e)&&e.toString===_c?JSON.stringify(e,null,2):String(e);function ym(e,t=""){return e.reduce((n,s,l)=>l===0?n+s:n+t+s,"")}function To(e){let t=e;return()=>++t}const Ks=e=>!xe(e)||Pe(e);function Qs(e,t){if(Ks(e)||Ks(t))throw new Error("Invalid value");const n=[{src:e,des:t}];for(;n.length;){const{src:s,des:l}=n.pop();Object.keys(s).forEach(o=>{o!=="__proto__"&&(xe(s[o])&&!xe(l[o])&&(l[o]=Array.isArray(s[o])?[]:Te()),Ks(l[o])||Ks(s[o])?l[o]=s[o]:n.push({src:s[o],des:l[o]}))})}}function wm(e,t,n){return{line:e,column:t,offset:n}}function co(e,t,n){return{start:e,end:t}}const xm=/\{([0-9a-zA-Z]+)\}/g;function wc(e,...t){return t.length===1&&Em(t[0])&&(t=t[0]),(!t||!t.hasOwnProperty)&&(t={}),e.replace(xm,(n,s)=>t.hasOwnProperty(s)?t[s]:"")}const xc=Object.assign,sa=e=>typeof e=="string",Em=e=>e!==null&&typeof e=="object";function Ec(e,t=""){return e.reduce((n,s,l)=>l===0?n+s:n+t+s,"")}const Zl={USE_MODULO_SYNTAX:1,__EXTEND_POINT__:2},km={[Zl.USE_MODULO_SYNTAX]:"Use modulo before '{{0}}'."};function Cm(e,t,...n){const s=wc(km[e],...n||[]),l={message:String(s),code:e};return t&&(l.location=t),l}const ie={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14,UNHANDLED_CODEGEN_NODE_TYPE:15,UNHANDLED_MINIFIER_NODE_TYPE:16,__EXTEND_POINT__:17},Sm={[ie.EXPECTED_TOKEN]:"Expected token: '{0}'",[ie.INVALID_TOKEN_IN_PLACEHOLDER]:"Invalid token in placeholder: '{0}'",[ie.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER]:"Unterminated single quote in placeholder",[ie.UNKNOWN_ESCAPE_SEQUENCE]:"Unknown escape sequence: \\{0}",[ie.INVALID_UNICODE_ESCAPE_SEQUENCE]:"Invalid unicode escape sequence: {0}",[ie.UNBALANCED_CLOSING_BRACE]:"Unbalanced closing brace",[ie.UNTERMINATED_CLOSING_BRACE]:"Unterminated closing brace",[ie.EMPTY_PLACEHOLDER]:"Empty placeholder",[ie.NOT_ALLOW_NEST_PLACEHOLDER]:"Not allowed nest placeholder",[ie.INVALID_LINKED_FORMAT]:"Invalid linked format",[ie.MUST_HAVE_MESSAGES_IN_PLURAL]:"Plural must have messages",[ie.UNEXPECTED_EMPTY_LINKED_MODIFIER]:"Unexpected empty linked modifier",[ie.UNEXPECTED_EMPTY_LINKED_KEY]:"Unexpected empty linked key",[ie.UNEXPECTED_LEXICAL_ANALYSIS]:"Unexpected lexical analysis in token: '{0}'",[ie.UNHANDLED_CODEGEN_NODE_TYPE]:"unhandled codegen node type: '{0}'",[ie.UNHANDLED_MINIFIER_NODE_TYPE]:"unhandled mimifier node type: '{0}'"};function os(e,t,n={}){const{domain:s,messages:l,args:o}=n,r=wc((l||Sm)[e]||"",...o||[]),a=new SyntaxError(String(r));return a.code=e,t&&(a.location=t),a.domain=s,a}function Tm(e){throw e}const jt=" ",Lm="\r",ut=`
|
|
2
|
+
`,$m="\u2028",Nm="\u2029";function Im(e){const t=e;let n=0,s=1,l=1,o=0;const r=S=>t[S]===Lm&&t[S+1]===ut,a=S=>t[S]===ut,i=S=>t[S]===Nm,u=S=>t[S]===$m,f=S=>r(S)||a(S)||i(S)||u(S),d=()=>n,m=()=>s,g=()=>l,C=()=>o,k=S=>r(S)||i(S)||u(S)?ut:t[S],N=()=>k(n),O=()=>k(n+o);function I(){return o=0,f(n)&&(s++,l=0),r(n)&&n++,n++,l++,t[n]}function b(){return r(n+o)&&o++,o++,t[n+o]}function v(){n=0,s=1,l=1,o=0}function T(S=0){o=S}function $(){const S=n+o;for(;S!==n;)I();o=0}return{index:d,line:m,column:g,peekOffset:C,charAt:k,currentChar:N,currentPeek:O,next:I,peek:b,reset:v,resetPeek:T,skipToPeek:$}}const sn=void 0,Pm=".",oa="'",Am="tokenizer";function Dm(e,t={}){const n=t.location!==!1,s=Im(e),l=()=>s.index(),o=()=>wm(s.line(),s.column(),s.index()),r=o(),a=l(),i={currentType:14,offset:a,startLoc:r,endLoc:r,lastType:14,lastOffset:a,lastStartLoc:r,lastEndLoc:r,braceNest:0,inLinked:!1,text:""},u=()=>i,{onError:f}=t;function d(p,h,D,...U){const J=u();if(h.column+=D,h.offset+=D,f){const G=n?co(J.startLoc,h):null,A=os(p,G,{domain:Am,args:U});f(A)}}function m(p,h,D){p.endLoc=o(),p.currentType=h;const U={type:h};return n&&(U.loc=co(p.startLoc,p.endLoc)),D!=null&&(U.value=D),U}const g=p=>m(p,14);function C(p,h){return p.currentChar()===h?(p.next(),h):(d(ie.EXPECTED_TOKEN,o(),0,h),"")}function k(p){let h="";for(;p.currentPeek()===jt||p.currentPeek()===ut;)h+=p.currentPeek(),p.peek();return h}function N(p){const h=k(p);return p.skipToPeek(),h}function O(p){if(p===sn)return!1;const h=p.charCodeAt(0);return h>=97&&h<=122||h>=65&&h<=90||h===95}function I(p){if(p===sn)return!1;const h=p.charCodeAt(0);return h>=48&&h<=57}function b(p,h){const{currentType:D}=h;if(D!==2)return!1;k(p);const U=O(p.currentPeek());return p.resetPeek(),U}function v(p,h){const{currentType:D}=h;if(D!==2)return!1;k(p);const U=p.currentPeek()==="-"?p.peek():p.currentPeek(),J=I(U);return p.resetPeek(),J}function T(p,h){const{currentType:D}=h;if(D!==2)return!1;k(p);const U=p.currentPeek()===oa;return p.resetPeek(),U}function $(p,h){const{currentType:D}=h;if(D!==8)return!1;k(p);const U=p.currentPeek()===".";return p.resetPeek(),U}function S(p,h){const{currentType:D}=h;if(D!==9)return!1;k(p);const U=O(p.currentPeek());return p.resetPeek(),U}function L(p,h){const{currentType:D}=h;if(!(D===8||D===12))return!1;k(p);const U=p.currentPeek()===":";return p.resetPeek(),U}function x(p,h){const{currentType:D}=h;if(D!==10)return!1;const U=()=>{const G=p.currentPeek();return G==="{"?O(p.peek()):G==="@"||G==="%"||G==="|"||G===":"||G==="."||G===jt||!G?!1:G===ut?(p.peek(),U()):P(p,!1)},J=U();return p.resetPeek(),J}function H(p){k(p);const h=p.currentPeek()==="|";return p.resetPeek(),h}function M(p){const h=k(p),D=p.currentPeek()==="%"&&p.peek()==="{";return p.resetPeek(),{isModulo:D,hasSpace:h.length>0}}function P(p,h=!0){const D=(J=!1,G="",A=!1)=>{const V=p.currentPeek();return V==="{"?G==="%"?!1:J:V==="@"||!V?G==="%"?!0:J:V==="%"?(p.peek(),D(J,"%",!0)):V==="|"?G==="%"||A?!0:!(G===jt||G===ut):V===jt?(p.peek(),D(!0,jt,A)):V===ut?(p.peek(),D(!0,ut,A)):!0},U=D();return h&&p.resetPeek(),U}function Y(p,h){const D=p.currentChar();return D===sn?sn:h(D)?(p.next(),D):null}function Se(p){const h=p.charCodeAt(0);return h>=97&&h<=122||h>=65&&h<=90||h>=48&&h<=57||h===95||h===36}function Re(p){return Y(p,Se)}function de(p){const h=p.charCodeAt(0);return h>=97&&h<=122||h>=65&&h<=90||h>=48&&h<=57||h===95||h===36||h===45}function ae(p){return Y(p,de)}function pe(p){const h=p.charCodeAt(0);return h>=48&&h<=57}function Xe(p){return Y(p,pe)}function tt(p){const h=p.charCodeAt(0);return h>=48&&h<=57||h>=65&&h<=70||h>=97&&h<=102}function Ae(p){return Y(p,tt)}function De(p){let h="",D="";for(;h=Xe(p);)D+=h;return D}function pt(p){N(p);const h=p.currentChar();return h!=="%"&&d(ie.EXPECTED_TOKEN,o(),0,h),p.next(),"%"}function B(p){let h="";for(;;){const D=p.currentChar();if(D==="{"||D==="}"||D==="@"||D==="|"||!D)break;if(D==="%")if(P(p))h+=D,p.next();else break;else if(D===jt||D===ut)if(P(p))h+=D,p.next();else{if(H(p))break;h+=D,p.next()}else h+=D,p.next()}return h}function le(p){N(p);let h="",D="";for(;h=ae(p);)D+=h;return p.currentChar()===sn&&d(ie.UNTERMINATED_CLOSING_BRACE,o(),0),D}function ve(p){N(p);let h="";return p.currentChar()==="-"?(p.next(),h+=`-${De(p)}`):h+=De(p),p.currentChar()===sn&&d(ie.UNTERMINATED_CLOSING_BRACE,o(),0),h}function F(p){return p!==oa&&p!==ut}function ee(p){N(p),C(p,"'");let h="",D="";for(;h=Y(p,F);)h==="\\"?D+=Q(p):D+=h;const U=p.currentChar();return U===ut||U===sn?(d(ie.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,o(),0),U===ut&&(p.next(),C(p,"'")),D):(C(p,"'"),D)}function Q(p){const h=p.currentChar();switch(h){case"\\":case"'":return p.next(),`\\${h}`;case"u":return ne(p,h,4);case"U":return ne(p,h,6);default:return d(ie.UNKNOWN_ESCAPE_SEQUENCE,o(),0,h),""}}function ne(p,h,D){C(p,h);let U="";for(let J=0;J<D;J++){const G=Ae(p);if(!G){d(ie.INVALID_UNICODE_ESCAPE_SEQUENCE,o(),0,`\\${h}${U}${p.currentChar()}`);break}U+=G}return`\\${h}${U}`}function me(p){return p!=="{"&&p!=="}"&&p!==jt&&p!==ut}function _(p){N(p);let h="",D="";for(;h=Y(p,me);)D+=h;return D}function w(p){let h="",D="";for(;h=Re(p);)D+=h;return D}function y(p){const h=D=>{const U=p.currentChar();return U==="{"||U==="%"||U==="@"||U==="|"||U==="("||U===")"||!U||U===jt?D:(D+=U,p.next(),h(D))};return h("")}function R(p){N(p);const h=C(p,"|");return N(p),h}function j(p,h){let D=null;switch(p.currentChar()){case"{":return h.braceNest>=1&&d(ie.NOT_ALLOW_NEST_PLACEHOLDER,o(),0),p.next(),D=m(h,2,"{"),N(p),h.braceNest++,D;case"}":return h.braceNest>0&&h.currentType===2&&d(ie.EMPTY_PLACEHOLDER,o(),0),p.next(),D=m(h,3,"}"),h.braceNest--,h.braceNest>0&&N(p),h.inLinked&&h.braceNest===0&&(h.inLinked=!1),D;case"@":return h.braceNest>0&&d(ie.UNTERMINATED_CLOSING_BRACE,o(),0),D=W(p,h)||g(h),h.braceNest=0,D;default:{let J=!0,G=!0,A=!0;if(H(p))return h.braceNest>0&&d(ie.UNTERMINATED_CLOSING_BRACE,o(),0),D=m(h,1,R(p)),h.braceNest=0,h.inLinked=!1,D;if(h.braceNest>0&&(h.currentType===5||h.currentType===6||h.currentType===7))return d(ie.UNTERMINATED_CLOSING_BRACE,o(),0),h.braceNest=0,z(p,h);if(J=b(p,h))return D=m(h,5,le(p)),N(p),D;if(G=v(p,h))return D=m(h,6,ve(p)),N(p),D;if(A=T(p,h))return D=m(h,7,ee(p)),N(p),D;if(!J&&!G&&!A)return D=m(h,13,_(p)),d(ie.INVALID_TOKEN_IN_PLACEHOLDER,o(),0,D.value),N(p),D;break}}return D}function W(p,h){const{currentType:D}=h;let U=null;const J=p.currentChar();switch((D===8||D===9||D===12||D===10)&&(J===ut||J===jt)&&d(ie.INVALID_LINKED_FORMAT,o(),0),J){case"@":return p.next(),U=m(h,8,"@"),h.inLinked=!0,U;case".":return N(p),p.next(),m(h,9,".");case":":return N(p),p.next(),m(h,10,":");default:return H(p)?(U=m(h,1,R(p)),h.braceNest=0,h.inLinked=!1,U):$(p,h)||L(p,h)?(N(p),W(p,h)):S(p,h)?(N(p),m(h,12,w(p))):x(p,h)?(N(p),J==="{"?j(p,h)||U:m(h,11,y(p))):(D===8&&d(ie.INVALID_LINKED_FORMAT,o(),0),h.braceNest=0,h.inLinked=!1,z(p,h))}}function z(p,h){let D={type:14};if(h.braceNest>0)return j(p,h)||g(h);if(h.inLinked)return W(p,h)||g(h);switch(p.currentChar()){case"{":return j(p,h)||g(h);case"}":return d(ie.UNBALANCED_CLOSING_BRACE,o(),0),p.next(),m(h,3,"}");case"@":return W(p,h)||g(h);default:{if(H(p))return D=m(h,1,R(p)),h.braceNest=0,h.inLinked=!1,D;const{isModulo:J,hasSpace:G}=M(p);if(J)return G?m(h,0,B(p)):m(h,4,pt(p));if(P(p))return m(h,0,B(p));break}}return D}function X(){const{currentType:p,offset:h,startLoc:D,endLoc:U}=i;return i.lastType=p,i.lastOffset=h,i.lastStartLoc=D,i.lastEndLoc=U,i.offset=l(),i.startLoc=o(),s.currentChar()===sn?m(i,14):z(s,i)}return{nextToken:X,currentOffset:l,currentPosition:o,context:u}}const Om="parser",Rm=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function Mm(e,t,n){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{const s=parseInt(t||n,16);return s<=55295||s>=57344?String.fromCodePoint(s):"�"}}}function Fm(e={}){const t=e.location!==!1,{onError:n,onWarn:s}=e;function l(b,v,T,$,...S){const L=b.currentPosition();if(L.offset+=$,L.column+=$,n){const x=t?co(T,L):null,H=os(v,x,{domain:Om,args:S});n(H)}}function o(b,v,T,$,...S){const L=b.currentPosition();if(L.offset+=$,L.column+=$,s){const x=t?co(T,L):null;s(Cm(v,x,S))}}function r(b,v,T){const $={type:b};return t&&($.start=v,$.end=v,$.loc={start:T,end:T}),$}function a(b,v,T,$){t&&(b.end=v,b.loc&&(b.loc.end=T))}function i(b,v){const T=b.context(),$=r(3,T.offset,T.startLoc);return $.value=v,a($,b.currentOffset(),b.currentPosition()),$}function u(b,v){const T=b.context(),{lastOffset:$,lastStartLoc:S}=T,L=r(5,$,S);return L.index=parseInt(v,10),b.nextToken(),a(L,b.currentOffset(),b.currentPosition()),L}function f(b,v,T){const $=b.context(),{lastOffset:S,lastStartLoc:L}=$,x=r(4,S,L);return x.key=v,T===!0&&(x.modulo=!0),b.nextToken(),a(x,b.currentOffset(),b.currentPosition()),x}function d(b,v){const T=b.context(),{lastOffset:$,lastStartLoc:S}=T,L=r(9,$,S);return L.value=v.replace(Rm,Mm),b.nextToken(),a(L,b.currentOffset(),b.currentPosition()),L}function m(b){const v=b.nextToken(),T=b.context(),{lastOffset:$,lastStartLoc:S}=T,L=r(8,$,S);return v.type!==12?(l(b,ie.UNEXPECTED_EMPTY_LINKED_MODIFIER,T.lastStartLoc,0),L.value="",a(L,$,S),{nextConsumeToken:v,node:L}):(v.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,T.lastStartLoc,0,kt(v)),L.value=v.value||"",a(L,b.currentOffset(),b.currentPosition()),{node:L})}function g(b,v){const T=b.context(),$=r(7,T.offset,T.startLoc);return $.value=v,a($,b.currentOffset(),b.currentPosition()),$}function C(b){const v=b.context(),T=r(6,v.offset,v.startLoc);let $=b.nextToken();if($.type===9){const S=m(b);T.modifier=S.node,$=S.nextConsumeToken||b.nextToken()}switch($.type!==10&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt($)),$=b.nextToken(),$.type===2&&($=b.nextToken()),$.type){case 11:$.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt($)),T.key=g(b,$.value||"");break;case 5:$.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt($)),T.key=f(b,$.value||"");break;case 6:$.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt($)),T.key=u(b,$.value||"");break;case 7:$.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt($)),T.key=d(b,$.value||"");break;default:{l(b,ie.UNEXPECTED_EMPTY_LINKED_KEY,v.lastStartLoc,0);const S=b.context(),L=r(7,S.offset,S.startLoc);return L.value="",a(L,S.offset,S.startLoc),T.key=L,a(T,S.offset,S.startLoc),{nextConsumeToken:$,node:T}}}return a(T,b.currentOffset(),b.currentPosition()),{node:T}}function k(b){const v=b.context(),T=v.currentType===1?b.currentOffset():v.offset,$=v.currentType===1?v.endLoc:v.startLoc,S=r(2,T,$);S.items=[];let L=null,x=null;do{const P=L||b.nextToken();switch(L=null,P.type){case 0:P.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt(P)),S.items.push(i(b,P.value||""));break;case 6:P.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt(P)),S.items.push(u(b,P.value||""));break;case 4:x=!0;break;case 5:P.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt(P)),S.items.push(f(b,P.value||"",!!x)),x&&(o(b,Zl.USE_MODULO_SYNTAX,v.lastStartLoc,0,kt(P)),x=null);break;case 7:P.value==null&&l(b,ie.UNEXPECTED_LEXICAL_ANALYSIS,v.lastStartLoc,0,kt(P)),S.items.push(d(b,P.value||""));break;case 8:{const Y=C(b);S.items.push(Y.node),L=Y.nextConsumeToken||null;break}}}while(v.currentType!==14&&v.currentType!==1);const H=v.currentType===1?v.lastOffset:b.currentOffset(),M=v.currentType===1?v.lastEndLoc:b.currentPosition();return a(S,H,M),S}function N(b,v,T,$){const S=b.context();let L=$.items.length===0;const x=r(1,v,T);x.cases=[],x.cases.push($);do{const H=k(b);L||(L=H.items.length===0),x.cases.push(H)}while(S.currentType!==14);return L&&l(b,ie.MUST_HAVE_MESSAGES_IN_PLURAL,T,0),a(x,b.currentOffset(),b.currentPosition()),x}function O(b){const v=b.context(),{offset:T,startLoc:$}=v,S=k(b);return v.currentType===14?S:N(b,T,$,S)}function I(b){const v=Dm(b,xc({},e)),T=v.context(),$=r(0,T.offset,T.startLoc);return t&&$.loc&&($.loc.source=b),$.body=O(v),e.onCacheKey&&($.cacheKey=e.onCacheKey(b)),T.currentType!==14&&l(v,ie.UNEXPECTED_LEXICAL_ANALYSIS,T.lastStartLoc,0,b[T.offset]||""),a($,v.currentOffset(),v.currentPosition()),$}return{parse:I}}function kt(e){if(e.type===14)return"EOF";const t=(e.value||"").replace(/\r?\n/gu,"\\n");return t.length>10?t.slice(0,9)+"…":t}function Um(e,t={}){const n={ast:e,helpers:new Set};return{context:()=>n,helper:o=>(n.helpers.add(o),o)}}function la(e,t){for(let n=0;n<e.length;n++)er(e[n],t)}function er(e,t){switch(e.type){case 1:la(e.cases,t),t.helper("plural");break;case 2:la(e.items,t);break;case 6:{er(e.key,t),t.helper("linked"),t.helper("type");break}case 5:t.helper("interpolate"),t.helper("list");break;case 4:t.helper("interpolate"),t.helper("named");break}}function Vm(e,t={}){const n=Um(e);n.helper("normalize"),e.body&&er(e.body,n);const s=n.context();e.helpers=Array.from(s.helpers)}function Hm(e){const t=e.body;return t.type===2?ra(t):t.cases.forEach(n=>ra(n)),e}function ra(e){if(e.items.length===1){const t=e.items[0];(t.type===3||t.type===9)&&(e.static=t.value,delete t.value)}else{const t=[];for(let n=0;n<e.items.length;n++){const s=e.items[n];if(!(s.type===3||s.type===9)||s.value==null)break;t.push(s.value)}if(t.length===e.items.length){e.static=Ec(t);for(let n=0;n<e.items.length;n++){const s=e.items[n];(s.type===3||s.type===9)&&delete s.value}}}}const Wm="minifier";function Wn(e){switch(e.t=e.type,e.type){case 0:{const t=e;Wn(t.body),t.b=t.body,delete t.body;break}case 1:{const t=e,n=t.cases;for(let s=0;s<n.length;s++)Wn(n[s]);t.c=n,delete t.cases;break}case 2:{const t=e,n=t.items;for(let s=0;s<n.length;s++)Wn(n[s]);t.i=n,delete t.items,t.static&&(t.s=t.static,delete t.static);break}case 3:case 9:case 8:case 7:{const t=e;t.value&&(t.v=t.value,delete t.value);break}case 6:{const t=e;Wn(t.key),t.k=t.key,delete t.key,t.modifier&&(Wn(t.modifier),t.m=t.modifier,delete t.modifier);break}case 5:{const t=e;t.i=t.index,delete t.index;break}case 4:{const t=e;t.k=t.key,delete t.key;break}default:throw os(ie.UNHANDLED_MINIFIER_NODE_TYPE,null,{domain:Wm,args:[e.type]})}delete e.type}const jm="parser";function Bm(e,t){const{filename:n,breakLineCode:s,needIndent:l}=t,o=t.location!==!1,r={filename:n,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:s,needIndent:l,indentLevel:0};o&&e.loc&&(r.source=e.loc.source);const a=()=>r;function i(k,N){r.code+=k}function u(k,N=!0){const O=N?s:"";i(l?O+" ".repeat(k):O)}function f(k=!0){const N=++r.indentLevel;k&&u(N)}function d(k=!0){const N=--r.indentLevel;k&&u(N)}function m(){u(r.indentLevel)}return{context:a,push:i,indent:f,deindent:d,newline:m,helper:k=>`_${k}`,needIndent:()=>r.needIndent}}function Gm(e,t){const{helper:n}=e;e.push(`${n("linked")}(`),Qn(e,t.key),t.modifier?(e.push(", "),Qn(e,t.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function Km(e,t){const{helper:n,needIndent:s}=e;e.push(`${n("normalize")}([`),e.indent(s());const l=t.items.length;for(let o=0;o<l&&(Qn(e,t.items[o]),o!==l-1);o++)e.push(", ");e.deindent(s()),e.push("])")}function Ym(e,t){const{helper:n,needIndent:s}=e;if(t.cases.length>1){e.push(`${n("plural")}([`),e.indent(s());const l=t.cases.length;for(let o=0;o<l&&(Qn(e,t.cases[o]),o!==l-1);o++)e.push(", ");e.deindent(s()),e.push("])")}}function qm(e,t){t.body?Qn(e,t.body):e.push("null")}function Qn(e,t){const{helper:n}=e;switch(t.type){case 0:qm(e,t);break;case 1:Ym(e,t);break;case 2:Km(e,t);break;case 6:Gm(e,t);break;case 8:e.push(JSON.stringify(t.value),t);break;case 7:e.push(JSON.stringify(t.value),t);break;case 5:e.push(`${n("interpolate")}(${n("list")}(${t.index}))`,t);break;case 4:e.push(`${n("interpolate")}(${n("named")}(${JSON.stringify(t.key)}))`,t);break;case 9:e.push(JSON.stringify(t.value),t);break;case 3:e.push(JSON.stringify(t.value),t);break;default:throw os(ie.UNHANDLED_CODEGEN_NODE_TYPE,null,{domain:jm,args:[t.type]})}}const Xm=(e,t={})=>{const n=sa(t.mode)?t.mode:"normal",s=sa(t.filename)?t.filename:"message.intl";t.sourceMap;const l=t.breakLineCode!=null?t.breakLineCode:n==="arrow"?";":`
|
|
3
|
+
`,o=t.needIndent?t.needIndent:n!=="arrow",r=e.helpers||[],a=Bm(e,{filename:s,breakLineCode:l,needIndent:o});a.push(n==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),a.indent(o),r.length>0&&(a.push(`const { ${Ec(r.map(f=>`${f}: _${f}`),", ")} } = ctx`),a.newline()),a.push("return "),Qn(a,e),a.deindent(o),a.push("}"),delete e.helpers;const{code:i,map:u}=a.context();return{ast:e,code:i,map:u?u.toJSON():void 0}};function zm(e,t={}){const n=xc({},t),s=!!n.jit,l=!!n.minify,o=n.optimize==null?!0:n.optimize,a=Fm(n).parse(e);return s?(o&&Hm(a),l&&Wn(a),{ast:a,code:""}):(Vm(a,n),Xm(a,n))}function Qm(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(zt().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_JIT_COMPILATION__!="boolean"&&(zt().__INTLIFY_JIT_COMPILATION__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(zt().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function Mt(e){return xe(e)&&tr(e)===0&&(Ct(e,"b")||Ct(e,"body"))}const kc=["b","body"];function Jm(e){return yn(e,kc)}const Cc=["c","cases"];function Zm(e){return yn(e,Cc,[])}const Sc=["s","static"];function ep(e){return yn(e,Sc)}const Tc=["i","items"];function tp(e){return yn(e,Tc,[])}const Lc=["t","type"];function tr(e){return yn(e,Lc)}const $c=["v","value"];function Ys(e,t){const n=yn(e,$c);if(n!=null)return n;throw Ls(t)}const Nc=["m","modifier"];function np(e){return yn(e,Nc)}const Ic=["k","key"];function sp(e){const t=yn(e,Ic);if(t)return t;throw Ls(6)}function yn(e,t,n){for(let s=0;s<t.length;s++){const l=t[s];if(Ct(e,l)&&e[l]!=null)return e[l]}return n}const Pc=[...kc,...Cc,...Sc,...Tc,...Ic,...Nc,...$c,...Lc];function Ls(e){return new Error(`unhandled node type: ${e}`)}const wn=[];wn[0]={w:[0],i:[3,0],"[":[4],o:[7]};wn[1]={w:[1],".":[2],"[":[4],o:[7]};wn[2]={w:[2],i:[3,0],0:[3,0]};wn[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]};wn[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]};wn[5]={"'":[4,0],o:8,l:[5,0]};wn[6]={'"':[4,0],o:8,l:[6,0]};const op=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function lp(e){return op.test(e)}function rp(e){const t=e.charCodeAt(0),n=e.charCodeAt(e.length-1);return t===n&&(t===34||t===39)?e.slice(1,-1):e}function ap(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function ip(e){const t=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:lp(t)?rp(t):"*"+t}function cp(e){const t=[];let n=-1,s=0,l=0,o,r,a,i,u,f,d;const m=[];m[0]=()=>{r===void 0?r=a:r+=a},m[1]=()=>{r!==void 0&&(t.push(r),r=void 0)},m[2]=()=>{m[0](),l++},m[3]=()=>{if(l>0)l--,s=4,m[0]();else{if(l=0,r===void 0||(r=ip(r),r===!1))return!1;m[1]()}};function g(){const C=e[n+1];if(s===5&&C==="'"||s===6&&C==='"')return n++,a="\\"+C,m[0](),!0}for(;s!==null;)if(n++,o=e[n],!(o==="\\"&&g())){if(i=ap(o),d=wn[s],u=d[i]||d.l||8,u===8||(s=u[0],u[1]!==void 0&&(f=m[u[1]],f&&(a=o,f()===!1))))return;if(s===7)return t}}const aa=new Map;function up(e,t){return xe(e)?e[t]:null}function fp(e,t){if(!xe(e))return null;let n=aa.get(t);if(n||(n=cp(t),n&&aa.set(t,n)),!n)return null;const s=n.length;let l=e,o=0;for(;o<s;){const r=n[o];if(Pc.includes(r)&&Mt(l))return null;const a=l[r];if(a===void 0||Ie(l))return null;l=a,o++}return l}const dp=e=>e,mp=e=>"",pp="text",hp=e=>e.length===0?"":ym(e),gp=_m;function ia(e,t){return e=Math.abs(e),t===2?e?e>1?1:0:1:e?Math.min(e,2):0}function vp(e){const t=He(e.pluralIndex)?e.pluralIndex:-1;return e.named&&(He(e.named.count)||He(e.named.n))?He(e.named.count)?e.named.count:He(e.named.n)?e.named.n:t:t}function bp(e,t){t.count||(t.count=e),t.n||(t.n=e)}function _p(e={}){const t=e.locale,n=vp(e),s=xe(e.pluralRules)&&te(t)&&Ie(e.pluralRules[t])?e.pluralRules[t]:ia,l=xe(e.pluralRules)&&te(t)&&Ie(e.pluralRules[t])?ia:void 0,o=O=>O[s(n,O.length,l)],r=e.list||[],a=O=>r[O],i=e.named||Te();He(e.pluralIndex)&&bp(n,i);const u=O=>i[O];function f(O){const I=Ie(e.messages)?e.messages(O):xe(e.messages)?e.messages[O]:!1;return I||(e.parent?e.parent.message(O):mp)}const d=O=>e.modifiers?e.modifiers[O]:dp,m=ce(e.processor)&&Ie(e.processor.normalize)?e.processor.normalize:hp,g=ce(e.processor)&&Ie(e.processor.interpolate)?e.processor.interpolate:gp,C=ce(e.processor)&&te(e.processor.type)?e.processor.type:pp,N={list:a,named:u,plural:o,linked:(O,...I)=>{const[b,v]=I;let T="text",$="";I.length===1?xe(b)?($=b.modifier||$,T=b.type||T):te(b)&&($=b||$):I.length===2&&(te(b)&&($=b||$),te(v)&&(T=v||T));const S=f(O)(N),L=T==="vnode"&&Pe(S)&&$?S[0]:S;return $?d($)(L,T):L},message:f,type:C,interpolate:g,normalize:m,values:et(Te(),r,i)};return N}let $s=null;function yp(e){$s=e}function wp(e,t,n){$s&&$s.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:t,meta:n})}const xp=Ep("function:translate");function Ep(e){return t=>$s&&$s.emit(e,t)}const kp=Zl.__EXTEND_POINT__,Tn=To(kp),Cp={FALLBACK_TO_TRANSLATE:Tn(),CANNOT_FORMAT_NUMBER:Tn(),FALLBACK_TO_NUMBER_FORMAT:Tn(),CANNOT_FORMAT_DATE:Tn(),FALLBACK_TO_DATE_FORMAT:Tn(),EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER:Tn(),__EXTEND_POINT__:Tn()},Ac=ie.__EXTEND_POINT__,Ln=To(Ac),St={INVALID_ARGUMENT:Ac,INVALID_DATE_ARGUMENT:Ln(),INVALID_ISO_DATE_ARGUMENT:Ln(),NOT_SUPPORT_NON_STRING_MESSAGE:Ln(),NOT_SUPPORT_LOCALE_PROMISE_VALUE:Ln(),NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:Ln(),NOT_SUPPORT_LOCALE_TYPE:Ln(),__EXTEND_POINT__:Ln()};function Ot(e){return os(e,null,void 0)}function nr(e,t){return t.locale!=null?ca(t.locale):ca(e.locale)}let qo;function ca(e){if(te(e))return e;if(Ie(e)){if(e.resolvedOnce&&qo!=null)return qo;if(e.constructor.name==="Function"){const t=e();if(bm(t))throw Ot(St.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return qo=t}else throw Ot(St.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw Ot(St.NOT_SUPPORT_LOCALE_TYPE)}function Sp(e,t,n){return[...new Set([n,...Pe(t)?t:xe(t)?Object.keys(t):te(t)?[t]:[n]])]}function Dc(e,t,n){const s=te(n)?n:Jn,l=e;l.__localeChainCache||(l.__localeChainCache=new Map);let o=l.__localeChainCache.get(s);if(!o){o=[];let r=[n];for(;Pe(r);)r=ua(o,r,t);const a=Pe(t)||!ce(t)?t:t.default?t.default:null;r=te(a)?[a]:a,Pe(r)&&ua(o,r,!1),l.__localeChainCache.set(s,o)}return o}function ua(e,t,n){let s=!0;for(let l=0;l<t.length&&he(s);l++){const o=t[l];te(o)&&(s=Tp(e,t[l],n))}return s}function Tp(e,t,n){let s;const l=t.split("-");do{const o=l.join("-");s=Lp(e,o,n),l.splice(-1,1)}while(l.length&&s===!0);return s}function Lp(e,t,n){let s=!1;if(!e.includes(t)&&(s=!0,t)){s=t[t.length-1]!=="!";const l=t.replace(/!/g,"");e.push(l),(Pe(n)||ce(n))&&n[l]&&(s=n[l])}return s}const $p="9.14.5",Lo=-1,Jn="en-US",fa="",da=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function Np(){return{upper:(e,t)=>t==="text"&&te(e)?e.toUpperCase():t==="vnode"&&xe(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,t)=>t==="text"&&te(e)?e.toLowerCase():t==="vnode"&&xe(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,t)=>t==="text"&&te(e)?da(e):t==="vnode"&&xe(e)&&"__v_isVNode"in e?da(e.children):e}}let Oc;function ma(e){Oc=e}let Rc;function Ip(e){Rc=e}let Mc;function Pp(e){Mc=e}let Fc=null;const Ap=e=>{Fc=e},Dp=()=>Fc;let Uc=null;const pa=e=>{Uc=e},Op=()=>Uc;let ha=0;function Rp(e={}){const t=Ie(e.onWarn)?e.onWarn:fm,n=te(e.version)?e.version:$p,s=te(e.locale)||Ie(e.locale)?e.locale:Jn,l=Ie(s)?Jn:s,o=Pe(e.fallbackLocale)||ce(e.fallbackLocale)||te(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:l,r=ce(e.messages)?e.messages:Xo(l),a=ce(e.datetimeFormats)?e.datetimeFormats:Xo(l),i=ce(e.numberFormats)?e.numberFormats:Xo(l),u=et(Te(),e.modifiers,Np()),f=e.pluralRules||Te(),d=Ie(e.missing)?e.missing:null,m=he(e.missingWarn)||vn(e.missingWarn)?e.missingWarn:!0,g=he(e.fallbackWarn)||vn(e.fallbackWarn)?e.fallbackWarn:!0,C=!!e.fallbackFormat,k=!!e.unresolving,N=Ie(e.postTranslation)?e.postTranslation:null,O=ce(e.processor)?e.processor:null,I=he(e.warnHtmlMessage)?e.warnHtmlMessage:!0,b=!!e.escapeParameter,v=Ie(e.messageCompiler)?e.messageCompiler:Oc,T=Ie(e.messageResolver)?e.messageResolver:Rc||up,$=Ie(e.localeFallbacker)?e.localeFallbacker:Mc||Sp,S=xe(e.fallbackContext)?e.fallbackContext:void 0,L=e,x=xe(L.__datetimeFormatters)?L.__datetimeFormatters:new Map,H=xe(L.__numberFormatters)?L.__numberFormatters:new Map,M=xe(L.__meta)?L.__meta:{};ha++;const P={version:n,cid:ha,locale:s,fallbackLocale:o,messages:r,modifiers:u,pluralRules:f,missing:d,missingWarn:m,fallbackWarn:g,fallbackFormat:C,unresolving:k,postTranslation:N,processor:O,warnHtmlMessage:I,escapeParameter:b,messageCompiler:v,messageResolver:T,localeFallbacker:$,fallbackContext:S,onWarn:t,__meta:M};return P.datetimeFormats=a,P.numberFormats=i,P.__datetimeFormatters=x,P.__numberFormatters=H,__INTLIFY_PROD_DEVTOOLS__&&wp(P,n,M),P}const Xo=e=>({[e]:Te()});function sr(e,t,n,s,l){const{missing:o,onWarn:r}=e;if(o!==null){const a=o(e,n,t,l);return te(a)?a:t}else return t}function as(e,t,n){const s=e;s.__localeChainCache=new Map,e.localeFallbacker(e,n,t)}function Mp(e,t){return e===t?!1:e.split("-")[0]===t.split("-")[0]}function Fp(e,t){const n=t.indexOf(e);if(n===-1)return!1;for(let s=n+1;s<t.length;s++)if(Mp(e,t[s]))return!0;return!1}function zo(e){return n=>Up(n,e)}function Up(e,t){const n=Jm(t);if(n==null)throw Ls(0);if(tr(n)===1){const o=Zm(n);return e.plural(o.reduce((r,a)=>[...r,ga(e,a)],[]))}else return ga(e,n)}function ga(e,t){const n=ep(t);if(n!=null)return e.type==="text"?n:e.normalize([n]);{const s=tp(t).reduce((l,o)=>[...l,hl(e,o)],[]);return e.normalize(s)}}function hl(e,t){const n=tr(t);switch(n){case 3:return Ys(t,n);case 9:return Ys(t,n);case 4:{const s=t;if(Ct(s,"k")&&s.k)return e.interpolate(e.named(s.k));if(Ct(s,"key")&&s.key)return e.interpolate(e.named(s.key));throw Ls(n)}case 5:{const s=t;if(Ct(s,"i")&&He(s.i))return e.interpolate(e.list(s.i));if(Ct(s,"index")&&He(s.index))return e.interpolate(e.list(s.index));throw Ls(n)}case 6:{const s=t,l=np(s),o=sp(s);return e.linked(hl(e,o),l?hl(e,l):void 0,e.type)}case 7:return Ys(t,n);case 8:return Ys(t,n);default:throw new Error(`unhandled node on format message part: ${n}`)}}const Vc=e=>e;let Gn=Te();function Hc(e,t={}){let n=!1;const s=t.onError||Tm;return t.onError=l=>{n=!0,s(l)},{...zm(e,t),detectError:n}}const Vp=(e,t)=>{if(!te(e))throw Ot(St.NOT_SUPPORT_NON_STRING_MESSAGE);{he(t.warnHtmlMessage)&&t.warnHtmlMessage;const s=(t.onCacheKey||Vc)(e),l=Gn[s];if(l)return l;const{code:o,detectError:r}=Hc(e,t),a=new Function(`return ${o}`)();return r?a:Gn[s]=a}};function Hp(e,t){if(__INTLIFY_JIT_COMPILATION__&&!__INTLIFY_DROP_MESSAGE_COMPILER__&&te(e)){he(t.warnHtmlMessage)&&t.warnHtmlMessage;const s=(t.onCacheKey||Vc)(e),l=Gn[s];if(l)return l;const{ast:o,detectError:r}=Hc(e,{...t,location:!1,jit:!0}),a=zo(o);return r?a:Gn[s]=a}else{const n=e.cacheKey;if(n){const s=Gn[n];return s||(Gn[n]=zo(e))}else return zo(e)}}const va=()=>"",wt=e=>Ie(e);function ba(e,...t){const{fallbackFormat:n,postTranslation:s,unresolving:l,messageCompiler:o,fallbackLocale:r,messages:a}=e,[i,u]=gl(...t),f=he(u.missingWarn)?u.missingWarn:e.missingWarn,d=he(u.fallbackWarn)?u.fallbackWarn:e.fallbackWarn,m=he(u.escapeParameter)?u.escapeParameter:e.escapeParameter,g=!!u.resolvedMessage,C=te(u.default)||he(u.default)?he(u.default)?o?i:()=>i:u.default:n?o?i:()=>i:"",k=n||C!=="",N=nr(e,u);m&&Wp(u);let[O,I,b]=g?[i,N,a[N]||Te()]:Wc(e,i,N,r,d,f),v=O,T=i;if(!g&&!(te(v)||Mt(v)||wt(v))&&k&&(v=C,T=v),!g&&(!(te(v)||Mt(v)||wt(v))||!te(I)))return l?Lo:i;let $=!1;const S=()=>{$=!0},L=wt(v)?v:jc(e,i,I,v,T,S);if($)return v;const x=Gp(e,I,b,u),H=_p(x),M=jp(e,L,H);let P=s?s(M,i):M;if(m&&te(P)&&(P=gm(P)),__INTLIFY_PROD_DEVTOOLS__){const Y={timestamp:Date.now(),key:te(i)?i:wt(v)?v.key:"",locale:I||(wt(v)?v.locale:""),format:te(v)?v:wt(v)?v.source:"",message:P};Y.meta=et({},e.__meta,Dp()||{}),xp(Y)}return P}function Wp(e){Pe(e.list)?e.list=e.list.map(t=>te(t)?ta(t):t):xe(e.named)&&Object.keys(e.named).forEach(t=>{te(e.named[t])&&(e.named[t]=ta(e.named[t]))})}function Wc(e,t,n,s,l,o){const{messages:r,onWarn:a,messageResolver:i,localeFallbacker:u}=e,f=u(e,s,n);let d=Te(),m,g=null;const C="translate";for(let k=0;k<f.length&&(m=f[k],d=r[m]||Te(),(g=i(d,t))===null&&(g=d[t]),!(te(g)||Mt(g)||wt(g)));k++)if(!Fp(m,f)){const N=sr(e,t,m,o,C);N!==t&&(g=N)}return[g,m,d]}function jc(e,t,n,s,l,o){const{messageCompiler:r,warnHtmlMessage:a}=e;if(wt(s)){const u=s;return u.locale=u.locale||n,u.key=u.key||t,u}if(r==null){const u=(()=>s);return u.locale=n,u.key=t,u}const i=r(s,Bp(e,n,l,s,a,o));return i.locale=n,i.key=t,i.source=s,i}function jp(e,t,n){return t(n)}function gl(...e){const[t,n,s]=e,l=Te();if(!te(t)&&!He(t)&&!wt(t)&&!Mt(t))throw Ot(St.INVALID_ARGUMENT);const o=He(t)?String(t):(wt(t),t);return He(n)?l.plural=n:te(n)?l.default=n:ce(n)&&!So(n)?l.named=n:Pe(n)&&(l.list=n),He(s)?l.plural=s:te(s)?l.default=s:ce(s)&&et(l,s),[o,l]}function Bp(e,t,n,s,l,o){return{locale:t,key:n,warnHtmlMessage:l,onError:r=>{throw o&&o(r),r},onCacheKey:r=>dm(t,n,r)}}function Gp(e,t,n,s){const{modifiers:l,pluralRules:o,messageResolver:r,fallbackLocale:a,fallbackWarn:i,missingWarn:u,fallbackContext:f}=e,m={locale:t,modifiers:l,pluralRules:o,messages:g=>{let C=r(n,g);if(C==null&&f){const[,,k]=Wc(f,g,t,a,i,u);C=r(k,g)}if(te(C)||Mt(C)){let k=!1;const O=jc(e,g,t,C,g,()=>{k=!0});return k?va:O}else return wt(C)?C:va}};return e.processor&&(m.processor=e.processor),s.list&&(m.list=s.list),s.named&&(m.named=s.named),He(s.plural)&&(m.pluralIndex=s.plural),m}function _a(e,...t){const{datetimeFormats:n,unresolving:s,fallbackLocale:l,onWarn:o,localeFallbacker:r}=e,{__datetimeFormatters:a}=e,[i,u,f,d]=vl(...t),m=he(f.missingWarn)?f.missingWarn:e.missingWarn;he(f.fallbackWarn)?f.fallbackWarn:e.fallbackWarn;const g=!!f.part,C=nr(e,f),k=r(e,l,C);if(!te(i)||i==="")return new Intl.DateTimeFormat(C,d).format(u);let N={},O,I=null;const b="datetime format";for(let $=0;$<k.length&&(O=k[$],N=n[O]||{},I=N[i],!ce(I));$++)sr(e,i,O,m,b);if(!ce(I)||!te(O))return s?Lo:i;let v=`${O}__${i}`;So(d)||(v=`${v}__${JSON.stringify(d)}`);let T=a.get(v);return T||(T=new Intl.DateTimeFormat(O,et({},I,d)),a.set(v,T)),g?T.formatToParts(u):T.format(u)}const Bc=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function vl(...e){const[t,n,s,l]=e,o=Te();let r=Te(),a;if(te(t)){const i=t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!i)throw Ot(St.INVALID_ISO_DATE_ARGUMENT);const u=i[3]?i[3].trim().startsWith("T")?`${i[1].trim()}${i[3].trim()}`:`${i[1].trim()}T${i[3].trim()}`:i[1].trim();a=new Date(u);try{a.toISOString()}catch{throw Ot(St.INVALID_ISO_DATE_ARGUMENT)}}else if(pm(t)){if(isNaN(t.getTime()))throw Ot(St.INVALID_DATE_ARGUMENT);a=t}else if(He(t))a=t;else throw Ot(St.INVALID_ARGUMENT);return te(n)?o.key=n:ce(n)&&Object.keys(n).forEach(i=>{Bc.includes(i)?r[i]=n[i]:o[i]=n[i]}),te(s)?o.locale=s:ce(s)&&(r=s),ce(l)&&(r=l),[o.key||"",a,o,r]}function ya(e,t,n){const s=e;for(const l in n){const o=`${t}__${l}`;s.__datetimeFormatters.has(o)&&s.__datetimeFormatters.delete(o)}}function wa(e,...t){const{numberFormats:n,unresolving:s,fallbackLocale:l,onWarn:o,localeFallbacker:r}=e,{__numberFormatters:a}=e,[i,u,f,d]=bl(...t),m=he(f.missingWarn)?f.missingWarn:e.missingWarn;he(f.fallbackWarn)?f.fallbackWarn:e.fallbackWarn;const g=!!f.part,C=nr(e,f),k=r(e,l,C);if(!te(i)||i==="")return new Intl.NumberFormat(C,d).format(u);let N={},O,I=null;const b="number format";for(let $=0;$<k.length&&(O=k[$],N=n[O]||{},I=N[i],!ce(I));$++)sr(e,i,O,m,b);if(!ce(I)||!te(O))return s?Lo:i;let v=`${O}__${i}`;So(d)||(v=`${v}__${JSON.stringify(d)}`);let T=a.get(v);return T||(T=new Intl.NumberFormat(O,et({},I,d)),a.set(v,T)),g?T.formatToParts(u):T.format(u)}const Gc=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function bl(...e){const[t,n,s,l]=e,o=Te();let r=Te();if(!He(t))throw Ot(St.INVALID_ARGUMENT);const a=t;return te(n)?o.key=n:ce(n)&&Object.keys(n).forEach(i=>{Gc.includes(i)?r[i]=n[i]:o[i]=n[i]}),te(s)?o.locale=s:ce(s)&&(r=s),ce(l)&&(r=l),[o.key||"",a,o,r]}function xa(e,t,n){const s=e;for(const l in n){const o=`${t}__${l}`;s.__numberFormatters.has(o)&&s.__numberFormatters.delete(o)}}Qm();const Kp="9.14.5";function Yp(){typeof __VUE_I18N_FULL_INSTALL__!="boolean"&&(zt().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!="boolean"&&(zt().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_JIT_COMPILATION__!="boolean"&&(zt().__INTLIFY_JIT_COMPILATION__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(zt().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(zt().__INTLIFY_PROD_DEVTOOLS__=!1)}const qp=Cp.__EXTEND_POINT__,Bt=To(qp);Bt(),Bt(),Bt(),Bt(),Bt(),Bt(),Bt(),Bt(),Bt();const Kc=St.__EXTEND_POINT__,ht=To(Kc),Ke={UNEXPECTED_RETURN_TYPE:Kc,INVALID_ARGUMENT:ht(),MUST_BE_CALL_SETUP_TOP:ht(),NOT_INSTALLED:ht(),NOT_AVAILABLE_IN_LEGACY_MODE:ht(),REQUIRED_VALUE:ht(),INVALID_VALUE:ht(),CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:ht(),NOT_INSTALLED_WITH_PROVIDE:ht(),UNEXPECTED_ERROR:ht(),NOT_COMPATIBLE_LEGACY_VUE_I18N:ht(),BRIDGE_SUPPORT_VUE_2_ONLY:ht(),MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION:ht(),NOT_AVAILABLE_COMPOSITION_IN_LEGACY:ht(),__EXTEND_POINT__:ht()};function Ye(e,...t){return os(e,null,void 0)}const _l=_n("__translateVNode"),yl=_n("__datetimeParts"),wl=_n("__numberParts"),Yc=_n("__setPluralRules"),qc=_n("__injectWithOption"),xl=_n("__dispose");function Ns(e){if(!xe(e)||Mt(e))return e;for(const t in e)if(Ct(e,t))if(!t.includes("."))xe(e[t])&&Ns(e[t]);else{const n=t.split("."),s=n.length-1;let l=e,o=!1;for(let r=0;r<s;r++){if(n[r]==="__proto__")throw new Error(`unsafe key: ${n[r]}`);if(n[r]in l||(l[n[r]]=Te()),!xe(l[n[r]])){o=!0;break}l=l[n[r]]}if(o||(Mt(l)?Pc.includes(n[s])||delete e[t]:(l[n[s]]=e[t],delete e[t])),!Mt(l)){const r=l[n[s]];xe(r)&&Ns(r)}}return e}function $o(e,t){const{messages:n,__i18n:s,messageResolver:l,flatJson:o}=t,r=ce(n)?n:Pe(s)?Te():{[e]:Te()};if(Pe(s)&&s.forEach(a=>{if("locale"in a&&"resource"in a){const{locale:i,resource:u}=a;i?(r[i]=r[i]||Te(),Qs(u,r[i])):Qs(u,r)}else te(a)&&Qs(JSON.parse(a),r)}),l==null&&o)for(const a in r)Ct(r,a)&&Ns(r[a]);return r}function Xc(e){return e.type}function zc(e,t,n){let s=xe(t.messages)?t.messages:Te();"__i18nGlobal"in n&&(s=$o(e.locale.value,{messages:s,__i18n:n.__i18nGlobal}));const l=Object.keys(s);l.length&&l.forEach(o=>{e.mergeLocaleMessage(o,s[o])});{if(xe(t.datetimeFormats)){const o=Object.keys(t.datetimeFormats);o.length&&o.forEach(r=>{e.mergeDateTimeFormat(r,t.datetimeFormats[r])})}if(xe(t.numberFormats)){const o=Object.keys(t.numberFormats);o.length&&o.forEach(r=>{e.mergeNumberFormat(r,t.numberFormats[r])})}}}function Ea(e){return ye(Ms,null,e,0)}const ka="__INTLIFY_META__",Ca=()=>[],Xp=()=>!1;let Sa=0;function Ta(e){return((t,n,s,l)=>e(n,s,hn()||void 0,l))}const zp=()=>{const e=hn();let t=null;return e&&(t=Xc(e)[ka])?{[ka]:t}:null};function or(e={},t){const{__root:n,__injectWithOption:s}=e,l=n===void 0,o=e.flatJson,r=io?q:jl,a=!!e.translateExistCompatible;let i=he(e.inheritLocale)?e.inheritLocale:!0;const u=r(n&&i?n.locale.value:te(e.locale)?e.locale:Jn),f=r(n&&i?n.fallbackLocale.value:te(e.fallbackLocale)||Pe(e.fallbackLocale)||ce(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:u.value),d=r($o(u.value,e)),m=r(ce(e.datetimeFormats)?e.datetimeFormats:{[u.value]:{}}),g=r(ce(e.numberFormats)?e.numberFormats:{[u.value]:{}});let C=n?n.missingWarn:he(e.missingWarn)||vn(e.missingWarn)?e.missingWarn:!0,k=n?n.fallbackWarn:he(e.fallbackWarn)||vn(e.fallbackWarn)?e.fallbackWarn:!0,N=n?n.fallbackRoot:he(e.fallbackRoot)?e.fallbackRoot:!0,O=!!e.fallbackFormat,I=Ie(e.missing)?e.missing:null,b=Ie(e.missing)?Ta(e.missing):null,v=Ie(e.postTranslation)?e.postTranslation:null,T=n?n.warnHtmlMessage:he(e.warnHtmlMessage)?e.warnHtmlMessage:!0,$=!!e.escapeParameter;const S=n?n.modifiers:ce(e.modifiers)?e.modifiers:{};let L=e.pluralRules||n&&n.pluralRules,x;x=(()=>{l&&pa(null);const A={version:Kp,locale:u.value,fallbackLocale:f.value,messages:d.value,modifiers:S,pluralRules:L,missing:b===null?void 0:b,missingWarn:C,fallbackWarn:k,fallbackFormat:O,unresolving:!0,postTranslation:v===null?void 0:v,warnHtmlMessage:T,escapeParameter:$,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};A.datetimeFormats=m.value,A.numberFormats=g.value,A.__datetimeFormatters=ce(x)?x.__datetimeFormatters:void 0,A.__numberFormatters=ce(x)?x.__numberFormatters:void 0;const V=Rp(A);return l&&pa(V),V})(),as(x,u.value,f.value);function M(){return[u.value,f.value,d.value,m.value,g.value]}const P=fe({get:()=>u.value,set:A=>{u.value=A,x.locale=u.value}}),Y=fe({get:()=>f.value,set:A=>{f.value=A,x.fallbackLocale=f.value,as(x,u.value,A)}}),Se=fe(()=>d.value),Re=fe(()=>m.value),de=fe(()=>g.value);function ae(){return Ie(v)?v:null}function pe(A){v=A,x.postTranslation=A}function Xe(){return I}function tt(A){A!==null&&(b=Ta(A)),I=A,x.missing=b}const Ae=(A,V,oe,ge,Me,it)=>{M();let ze;try{__INTLIFY_PROD_DEVTOOLS__,l||(x.fallbackContext=n?Op():void 0),ze=A(x)}finally{__INTLIFY_PROD_DEVTOOLS__,l||(x.fallbackContext=void 0)}if(oe!=="translate exists"&&He(ze)&&ze===Lo||oe==="translate exists"&&!ze){const[xn,Do]=V();return n&&N?ge(n):Me(xn)}else{if(it(ze))return ze;throw Ye(Ke.UNEXPECTED_RETURN_TYPE)}};function De(...A){return Ae(V=>Reflect.apply(ba,null,[V,...A]),()=>gl(...A),"translate",V=>Reflect.apply(V.t,V,[...A]),V=>V,V=>te(V))}function pt(...A){const[V,oe,ge]=A;if(ge&&!xe(ge))throw Ye(Ke.INVALID_ARGUMENT);return De(V,oe,et({resolvedMessage:!0},ge||{}))}function B(...A){return Ae(V=>Reflect.apply(_a,null,[V,...A]),()=>vl(...A),"datetime format",V=>Reflect.apply(V.d,V,[...A]),()=>fa,V=>te(V))}function le(...A){return Ae(V=>Reflect.apply(wa,null,[V,...A]),()=>bl(...A),"number format",V=>Reflect.apply(V.n,V,[...A]),()=>fa,V=>te(V))}function ve(A){return A.map(V=>te(V)||He(V)||he(V)?Ea(String(V)):V)}const ee={normalize:ve,interpolate:A=>A,type:"vnode"};function Q(...A){return Ae(V=>{let oe;const ge=V;try{ge.processor=ee,oe=Reflect.apply(ba,null,[ge,...A])}finally{ge.processor=null}return oe},()=>gl(...A),"translate",V=>V[_l](...A),V=>[Ea(V)],V=>Pe(V))}function ne(...A){return Ae(V=>Reflect.apply(wa,null,[V,...A]),()=>bl(...A),"number format",V=>V[wl](...A),Ca,V=>te(V)||Pe(V))}function me(...A){return Ae(V=>Reflect.apply(_a,null,[V,...A]),()=>vl(...A),"datetime format",V=>V[yl](...A),Ca,V=>te(V)||Pe(V))}function _(A){L=A,x.pluralRules=L}function w(A,V){return Ae(()=>{if(!A)return!1;const oe=te(V)?V:u.value,ge=j(oe),Me=x.messageResolver(ge,A);return a?Me!=null:Mt(Me)||wt(Me)||te(Me)},()=>[A],"translate exists",oe=>Reflect.apply(oe.te,oe,[A,V]),Xp,oe=>he(oe))}function y(A){let V=null;const oe=Dc(x,f.value,u.value);for(let ge=0;ge<oe.length;ge++){const Me=d.value[oe[ge]]||{},it=x.messageResolver(Me,A);if(it!=null){V=it;break}}return V}function R(A){const V=y(A);return V??(n?n.tm(A)||{}:{})}function j(A){return d.value[A]||{}}function W(A,V){if(o){const oe={[A]:V};for(const ge in oe)Ct(oe,ge)&&Ns(oe[ge]);V=oe[A]}d.value[A]=V,x.messages=d.value}function z(A,V){d.value[A]=d.value[A]||{};const oe={[A]:V};if(o)for(const ge in oe)Ct(oe,ge)&&Ns(oe[ge]);V=oe[A],Qs(V,d.value[A]),x.messages=d.value}function X(A){return m.value[A]||{}}function p(A,V){m.value[A]=V,x.datetimeFormats=m.value,ya(x,A,V)}function h(A,V){m.value[A]=et(m.value[A]||{},V),x.datetimeFormats=m.value,ya(x,A,V)}function D(A){return g.value[A]||{}}function U(A,V){g.value[A]=V,x.numberFormats=g.value,xa(x,A,V)}function J(A,V){g.value[A]=et(g.value[A]||{},V),x.numberFormats=g.value,xa(x,A,V)}Sa++,n&&io&&(mt(n.locale,A=>{i&&(u.value=A,x.locale=A,as(x,u.value,f.value))}),mt(n.fallbackLocale,A=>{i&&(f.value=A,x.fallbackLocale=A,as(x,u.value,f.value))}));const G={id:Sa,locale:P,fallbackLocale:Y,get inheritLocale(){return i},set inheritLocale(A){i=A,A&&n&&(u.value=n.locale.value,f.value=n.fallbackLocale.value,as(x,u.value,f.value))},get availableLocales(){return Object.keys(d.value).sort()},messages:Se,get modifiers(){return S},get pluralRules(){return L||{}},get isGlobal(){return l},get missingWarn(){return C},set missingWarn(A){C=A,x.missingWarn=C},get fallbackWarn(){return k},set fallbackWarn(A){k=A,x.fallbackWarn=k},get fallbackRoot(){return N},set fallbackRoot(A){N=A},get fallbackFormat(){return O},set fallbackFormat(A){O=A,x.fallbackFormat=O},get warnHtmlMessage(){return T},set warnHtmlMessage(A){T=A,x.warnHtmlMessage=A},get escapeParameter(){return $},set escapeParameter(A){$=A,x.escapeParameter=A},t:De,getLocaleMessage:j,setLocaleMessage:W,mergeLocaleMessage:z,getPostTranslationHandler:ae,setPostTranslationHandler:pe,getMissingHandler:Xe,setMissingHandler:tt,[Yc]:_};return G.datetimeFormats=Re,G.numberFormats=de,G.rt=pt,G.te=w,G.tm=R,G.d=B,G.n=le,G.getDateTimeFormat=X,G.setDateTimeFormat=p,G.mergeDateTimeFormat=h,G.getNumberFormat=D,G.setNumberFormat=U,G.mergeNumberFormat=J,G[qc]=s,G[_l]=Q,G[yl]=me,G[wl]=ne,G}function Qp(e){const t=te(e.locale)?e.locale:Jn,n=te(e.fallbackLocale)||Pe(e.fallbackLocale)||ce(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:t,s=Ie(e.missing)?e.missing:void 0,l=he(e.silentTranslationWarn)||vn(e.silentTranslationWarn)?!e.silentTranslationWarn:!0,o=he(e.silentFallbackWarn)||vn(e.silentFallbackWarn)?!e.silentFallbackWarn:!0,r=he(e.fallbackRoot)?e.fallbackRoot:!0,a=!!e.formatFallbackMessages,i=ce(e.modifiers)?e.modifiers:{},u=e.pluralizationRules,f=Ie(e.postTranslation)?e.postTranslation:void 0,d=te(e.warnHtmlInMessage)?e.warnHtmlInMessage!=="off":!0,m=!!e.escapeParameterHtml,g=he(e.sync)?e.sync:!0;let C=e.messages;if(ce(e.sharedMessages)){const $=e.sharedMessages;C=Object.keys($).reduce((L,x)=>{const H=L[x]||(L[x]={});return et(H,$[x]),L},C||{})}const{__i18n:k,__root:N,__injectWithOption:O}=e,I=e.datetimeFormats,b=e.numberFormats,v=e.flatJson,T=e.translateExistCompatible;return{locale:t,fallbackLocale:n,messages:C,flatJson:v,datetimeFormats:I,numberFormats:b,missing:s,missingWarn:l,fallbackWarn:o,fallbackRoot:r,fallbackFormat:a,modifiers:i,pluralRules:u,postTranslation:f,warnHtmlMessage:d,escapeParameter:m,messageResolver:e.messageResolver,inheritLocale:g,translateExistCompatible:T,__i18n:k,__root:N,__injectWithOption:O}}function El(e={},t){{const n=or(Qp(e)),{__extender:s}=e,l={id:n.id,get locale(){return n.locale.value},set locale(o){n.locale.value=o},get fallbackLocale(){return n.fallbackLocale.value},set fallbackLocale(o){n.fallbackLocale.value=o},get messages(){return n.messages.value},get datetimeFormats(){return n.datetimeFormats.value},get numberFormats(){return n.numberFormats.value},get availableLocales(){return n.availableLocales},get formatter(){return{interpolate(){return[]}}},set formatter(o){},get missing(){return n.getMissingHandler()},set missing(o){n.setMissingHandler(o)},get silentTranslationWarn(){return he(n.missingWarn)?!n.missingWarn:n.missingWarn},set silentTranslationWarn(o){n.missingWarn=he(o)?!o:o},get silentFallbackWarn(){return he(n.fallbackWarn)?!n.fallbackWarn:n.fallbackWarn},set silentFallbackWarn(o){n.fallbackWarn=he(o)?!o:o},get modifiers(){return n.modifiers},get formatFallbackMessages(){return n.fallbackFormat},set formatFallbackMessages(o){n.fallbackFormat=o},get postTranslation(){return n.getPostTranslationHandler()},set postTranslation(o){n.setPostTranslationHandler(o)},get sync(){return n.inheritLocale},set sync(o){n.inheritLocale=o},get warnHtmlInMessage(){return n.warnHtmlMessage?"warn":"off"},set warnHtmlInMessage(o){n.warnHtmlMessage=o!=="off"},get escapeParameterHtml(){return n.escapeParameter},set escapeParameterHtml(o){n.escapeParameter=o},get preserveDirectiveContent(){return!0},set preserveDirectiveContent(o){},get pluralizationRules(){return n.pluralRules||{}},__composer:n,t(...o){const[r,a,i]=o,u={};let f=null,d=null;if(!te(r))throw Ye(Ke.INVALID_ARGUMENT);const m=r;return te(a)?u.locale=a:Pe(a)?f=a:ce(a)&&(d=a),Pe(i)?f=i:ce(i)&&(d=i),Reflect.apply(n.t,n,[m,f||d||{},u])},rt(...o){return Reflect.apply(n.rt,n,[...o])},tc(...o){const[r,a,i]=o,u={plural:1};let f=null,d=null;if(!te(r))throw Ye(Ke.INVALID_ARGUMENT);const m=r;return te(a)?u.locale=a:He(a)?u.plural=a:Pe(a)?f=a:ce(a)&&(d=a),te(i)?u.locale=i:Pe(i)?f=i:ce(i)&&(d=i),Reflect.apply(n.t,n,[m,f||d||{},u])},te(o,r){return n.te(o,r)},tm(o){return n.tm(o)},getLocaleMessage(o){return n.getLocaleMessage(o)},setLocaleMessage(o,r){n.setLocaleMessage(o,r)},mergeLocaleMessage(o,r){n.mergeLocaleMessage(o,r)},d(...o){return Reflect.apply(n.d,n,[...o])},getDateTimeFormat(o){return n.getDateTimeFormat(o)},setDateTimeFormat(o,r){n.setDateTimeFormat(o,r)},mergeDateTimeFormat(o,r){n.mergeDateTimeFormat(o,r)},n(...o){return Reflect.apply(n.n,n,[...o])},getNumberFormat(o){return n.getNumberFormat(o)},setNumberFormat(o,r){n.setNumberFormat(o,r)},mergeNumberFormat(o,r){n.mergeNumberFormat(o,r)},getChoiceIndex(o,r){return-1}};return l.__extender=s,l}}const lr={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};function Jp({slots:e},t){return t.length===1&&t[0]==="default"?(e.default?e.default():[]).reduce((s,l)=>[...s,...l.type===Ge?l.children:[l]],[]):t.reduce((n,s)=>{const l=e[s];return l&&(n[s]=l()),n},Te())}function Qc(e){return Ge}const Zp=Oe({name:"i18n-t",props:et({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>He(e)||!isNaN(e)}},lr),setup(e,t){const{slots:n,attrs:s}=t,l=e.i18n||je({useScope:e.scope,__useComponent:!0});return()=>{const o=Object.keys(n).filter(d=>d!=="_"),r=Te();e.locale&&(r.locale=e.locale),e.plural!==void 0&&(r.plural=te(e.plural)?+e.plural:e.plural);const a=Jp(t,o),i=l[_l](e.keypath,a,r),u=et(Te(),s),f=te(e.tag)||xe(e.tag)?e.tag:Qc();return Us(f,u,i)}}}),La=Zp;function eh(e){return Pe(e)&&!te(e[0])}function Jc(e,t,n,s){const{slots:l,attrs:o}=t;return()=>{const r={part:!0};let a=Te();e.locale&&(r.locale=e.locale),te(e.format)?r.key=e.format:xe(e.format)&&(te(e.format.key)&&(r.key=e.format.key),a=Object.keys(e.format).reduce((m,g)=>n.includes(g)?et(Te(),m,{[g]:e.format[g]}):m,Te()));const i=s(e.value,r,a);let u=[r.key];Pe(i)?u=i.map((m,g)=>{const C=l[m.type],k=C?C({[m.type]:m.value,index:g,parts:i}):[m.value];return eh(k)&&(k[0].key=`${m.type}-${g}`),k}):te(i)&&(u=[i]);const f=et(Te(),o),d=te(e.tag)||xe(e.tag)?e.tag:Qc();return Us(d,f,u)}}const th=Oe({name:"i18n-n",props:et({value:{type:Number,required:!0},format:{type:[String,Object]}},lr),setup(e,t){const n=e.i18n||je({useScope:e.scope,__useComponent:!0});return Jc(e,t,Gc,(...s)=>n[wl](...s))}}),$a=th,nh=Oe({name:"i18n-d",props:et({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},lr),setup(e,t){const n=e.i18n||je({useScope:e.scope,__useComponent:!0});return Jc(e,t,Bc,(...s)=>n[yl](...s))}}),Na=nh;function sh(e,t){const n=e;if(e.mode==="composition")return n.__getInstance(t)||e.global;{const s=n.__getInstance(t);return s!=null?s.__composer:e.global.__composer}}function oh(e){const t=r=>{const{instance:a,modifiers:i,value:u}=r;if(!a||!a.$)throw Ye(Ke.UNEXPECTED_ERROR);const f=sh(e,a.$),d=Ia(u);return[Reflect.apply(f.t,f,[...Pa(d)]),f]};return{created:(r,a)=>{const[i,u]=t(a);io&&e.global===u&&(r.__i18nWatcher=mt(u.locale,()=>{a.instance&&a.instance.$forceUpdate()})),r.__composer=u,r.textContent=i},unmounted:r=>{io&&r.__i18nWatcher&&(r.__i18nWatcher(),r.__i18nWatcher=void 0,delete r.__i18nWatcher),r.__composer&&(r.__composer=void 0,delete r.__composer)},beforeUpdate:(r,{value:a})=>{if(r.__composer){const i=r.__composer,u=Ia(a);r.textContent=Reflect.apply(i.t,i,[...Pa(u)])}},getSSRProps:r=>{const[a]=t(r);return{textContent:a}}}}function Ia(e){if(te(e))return{path:e};if(ce(e)){if(!("path"in e))throw Ye(Ke.REQUIRED_VALUE,"path");return e}else throw Ye(Ke.INVALID_VALUE)}function Pa(e){const{path:t,locale:n,args:s,choice:l,plural:o}=e,r={},a=s||{};return te(n)&&(r.locale=n),He(l)&&(r.plural=l),He(o)&&(r.plural=o),[t,a,r]}function lh(e,t,...n){const s=ce(n[0])?n[0]:{},l=!!s.useI18nComponentName;(he(s.globalInstall)?s.globalInstall:!0)&&([l?"i18n":La.name,"I18nT"].forEach(r=>e.component(r,La)),[$a.name,"I18nN"].forEach(r=>e.component(r,$a)),[Na.name,"I18nD"].forEach(r=>e.component(r,Na))),e.directive("t",oh(t))}function rh(e,t,n){return{beforeCreate(){const s=hn();if(!s)throw Ye(Ke.UNEXPECTED_ERROR);const l=this.$options;if(l.i18n){const o=l.i18n;if(l.__i18n&&(o.__i18n=l.__i18n),o.__root=t,this===this.$root)this.$i18n=Aa(e,o);else{o.__injectWithOption=!0,o.__extender=n.__vueI18nExtend,this.$i18n=El(o);const r=this.$i18n;r.__extender&&(r.__disposer=r.__extender(this.$i18n))}}else if(l.__i18n)if(this===this.$root)this.$i18n=Aa(e,l);else{this.$i18n=El({__i18n:l.__i18n,__injectWithOption:!0,__extender:n.__vueI18nExtend,__root:t});const o=this.$i18n;o.__extender&&(o.__disposer=o.__extender(this.$i18n))}else this.$i18n=e;l.__i18nGlobal&&zc(t,l,l),this.$t=(...o)=>this.$i18n.t(...o),this.$rt=(...o)=>this.$i18n.rt(...o),this.$tc=(...o)=>this.$i18n.tc(...o),this.$te=(o,r)=>this.$i18n.te(o,r),this.$d=(...o)=>this.$i18n.d(...o),this.$n=(...o)=>this.$i18n.n(...o),this.$tm=o=>this.$i18n.tm(o),n.__setInstance(s,this.$i18n)},mounted(){},unmounted(){const s=hn();if(!s)throw Ye(Ke.UNEXPECTED_ERROR);const l=this.$i18n;delete this.$t,delete this.$rt,delete this.$tc,delete this.$te,delete this.$d,delete this.$n,delete this.$tm,l.__disposer&&(l.__disposer(),delete l.__disposer,delete l.__extender),n.__deleteInstance(s),delete this.$i18n}}}function Aa(e,t){e.locale=t.locale||e.locale,e.fallbackLocale=t.fallbackLocale||e.fallbackLocale,e.missing=t.missing||e.missing,e.silentTranslationWarn=t.silentTranslationWarn||e.silentFallbackWarn,e.silentFallbackWarn=t.silentFallbackWarn||e.silentFallbackWarn,e.formatFallbackMessages=t.formatFallbackMessages||e.formatFallbackMessages,e.postTranslation=t.postTranslation||e.postTranslation,e.warnHtmlInMessage=t.warnHtmlInMessage||e.warnHtmlInMessage,e.escapeParameterHtml=t.escapeParameterHtml||e.escapeParameterHtml,e.sync=t.sync||e.sync,e.__composer[Yc](t.pluralizationRules||e.pluralizationRules);const n=$o(e.locale,{messages:t.messages,__i18n:t.__i18n});return Object.keys(n).forEach(s=>e.mergeLocaleMessage(s,n[s])),t.datetimeFormats&&Object.keys(t.datetimeFormats).forEach(s=>e.mergeDateTimeFormat(s,t.datetimeFormats[s])),t.numberFormats&&Object.keys(t.numberFormats).forEach(s=>e.mergeNumberFormat(s,t.numberFormats[s])),e}const ah=_n("global-vue-i18n");function ih(e={},t){const n=__VUE_I18N_LEGACY_API__&&he(e.legacy)?e.legacy:__VUE_I18N_LEGACY_API__,s=he(e.globalInjection)?e.globalInjection:!0,l=__VUE_I18N_LEGACY_API__&&n?!!e.allowComposition:!0,o=new Map,[r,a]=ch(e,n),i=_n("");function u(m){return o.get(m)||null}function f(m,g){o.set(m,g)}function d(m){o.delete(m)}{const m={get mode(){return __VUE_I18N_LEGACY_API__&&n?"legacy":"composition"},get allowComposition(){return l},async install(g,...C){if(g.__VUE_I18N_SYMBOL__=i,g.provide(g.__VUE_I18N_SYMBOL__,m),ce(C[0])){const O=C[0];m.__composerExtend=O.__composerExtend,m.__vueI18nExtend=O.__vueI18nExtend}let k=null;!n&&s&&(k=bh(g,m.global)),__VUE_I18N_FULL_INSTALL__&&lh(g,m,...C),__VUE_I18N_LEGACY_API__&&n&&g.mixin(rh(a,a.__composer,m));const N=g.unmount;g.unmount=()=>{k&&k(),m.dispose(),N()}},get global(){return a},dispose(){r.stop()},__instances:o,__getInstance:u,__setInstance:f,__deleteInstance:d};return m}}function je(e={}){const t=hn();if(t==null)throw Ye(Ke.MUST_BE_CALL_SETUP_TOP);if(!t.isCE&&t.appContext.app!=null&&!t.appContext.app.__VUE_I18N_SYMBOL__)throw Ye(Ke.NOT_INSTALLED);const n=uh(t),s=dh(n),l=Xc(t),o=fh(e,l);if(__VUE_I18N_LEGACY_API__&&n.mode==="legacy"&&!e.__useComponent){if(!n.allowComposition)throw Ye(Ke.NOT_AVAILABLE_IN_LEGACY_MODE);return gh(t,o,s,e)}if(o==="global")return zc(s,e,l),s;if(o==="parent"){let i=mh(n,t,e.__useComponent);return i==null&&(i=s),i}const r=n;let a=r.__getInstance(t);if(a==null){const i=et({},e);"__i18n"in l&&(i.__i18n=l.__i18n),s&&(i.__root=s),a=or(i),r.__composerExtend&&(a[xl]=r.__composerExtend(a)),hh(r,t,a),r.__setInstance(t,a)}return a}function ch(e,t,n){const s=Dl();{const l=__VUE_I18N_LEGACY_API__&&t?s.run(()=>El(e)):s.run(()=>or(e));if(l==null)throw Ye(Ke.UNEXPECTED_ERROR);return[s,l]}}function uh(e){{const t=gt(e.isCE?ah:e.appContext.app.__VUE_I18N_SYMBOL__);if(!t)throw Ye(e.isCE?Ke.NOT_INSTALLED_WITH_PROVIDE:Ke.UNEXPECTED_ERROR);return t}}function fh(e,t){return So(e)?"__i18n"in t?"local":"global":e.useScope?e.useScope:"local"}function dh(e){return e.mode==="composition"?e.global:e.global.__composer}function mh(e,t,n=!1){let s=null;const l=t.root;let o=ph(t,n);for(;o!=null;){const r=e;if(e.mode==="composition")s=r.__getInstance(o);else if(__VUE_I18N_LEGACY_API__){const a=r.__getInstance(o);a!=null&&(s=a.__composer,n&&s&&!s[qc]&&(s=null))}if(s!=null||l===o)break;o=o.parent}return s}function ph(e,t=!1){return e==null?null:t&&e.vnode.ctx||e.parent}function hh(e,t,n){Vt(()=>{},t),On(()=>{const s=n;e.__deleteInstance(t);const l=s[xl];l&&(l(),delete s[xl])},t)}function gh(e,t,n,s={}){const l=t==="local",o=jl(null);if(l&&e.proxy&&!(e.proxy.$options.i18n||e.proxy.$options.__i18n))throw Ye(Ke.MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION);const r=he(s.inheritLocale)?s.inheritLocale:!te(s.locale),a=q(!l||r?n.locale.value:te(s.locale)?s.locale:Jn),i=q(!l||r?n.fallbackLocale.value:te(s.fallbackLocale)||Pe(s.fallbackLocale)||ce(s.fallbackLocale)||s.fallbackLocale===!1?s.fallbackLocale:a.value),u=q($o(a.value,s)),f=q(ce(s.datetimeFormats)?s.datetimeFormats:{[a.value]:{}}),d=q(ce(s.numberFormats)?s.numberFormats:{[a.value]:{}}),m=l?n.missingWarn:he(s.missingWarn)||vn(s.missingWarn)?s.missingWarn:!0,g=l?n.fallbackWarn:he(s.fallbackWarn)||vn(s.fallbackWarn)?s.fallbackWarn:!0,C=l?n.fallbackRoot:he(s.fallbackRoot)?s.fallbackRoot:!0,k=!!s.fallbackFormat,N=Ie(s.missing)?s.missing:null,O=Ie(s.postTranslation)?s.postTranslation:null,I=l?n.warnHtmlMessage:he(s.warnHtmlMessage)?s.warnHtmlMessage:!0,b=!!s.escapeParameter,v=l?n.modifiers:ce(s.modifiers)?s.modifiers:{},T=s.pluralRules||l&&n.pluralRules;function $(){return[a.value,i.value,u.value,f.value,d.value]}const S=fe({get:()=>o.value?o.value.locale.value:a.value,set:y=>{o.value&&(o.value.locale.value=y),a.value=y}}),L=fe({get:()=>o.value?o.value.fallbackLocale.value:i.value,set:y=>{o.value&&(o.value.fallbackLocale.value=y),i.value=y}}),x=fe(()=>o.value?o.value.messages.value:u.value),H=fe(()=>f.value),M=fe(()=>d.value);function P(){return o.value?o.value.getPostTranslationHandler():O}function Y(y){o.value&&o.value.setPostTranslationHandler(y)}function Se(){return o.value?o.value.getMissingHandler():N}function Re(y){o.value&&o.value.setMissingHandler(y)}function de(y){return $(),y()}function ae(...y){return o.value?de(()=>Reflect.apply(o.value.t,null,[...y])):de(()=>"")}function pe(...y){return o.value?Reflect.apply(o.value.rt,null,[...y]):""}function Xe(...y){return o.value?de(()=>Reflect.apply(o.value.d,null,[...y])):de(()=>"")}function tt(...y){return o.value?de(()=>Reflect.apply(o.value.n,null,[...y])):de(()=>"")}function Ae(y){return o.value?o.value.tm(y):{}}function De(y,R){return o.value?o.value.te(y,R):!1}function pt(y){return o.value?o.value.getLocaleMessage(y):{}}function B(y,R){o.value&&(o.value.setLocaleMessage(y,R),u.value[y]=R)}function le(y,R){o.value&&o.value.mergeLocaleMessage(y,R)}function ve(y){return o.value?o.value.getDateTimeFormat(y):{}}function F(y,R){o.value&&(o.value.setDateTimeFormat(y,R),f.value[y]=R)}function ee(y,R){o.value&&o.value.mergeDateTimeFormat(y,R)}function Q(y){return o.value?o.value.getNumberFormat(y):{}}function ne(y,R){o.value&&(o.value.setNumberFormat(y,R),d.value[y]=R)}function me(y,R){o.value&&o.value.mergeNumberFormat(y,R)}const _={get id(){return o.value?o.value.id:-1},locale:S,fallbackLocale:L,messages:x,datetimeFormats:H,numberFormats:M,get inheritLocale(){return o.value?o.value.inheritLocale:r},set inheritLocale(y){o.value&&(o.value.inheritLocale=y)},get availableLocales(){return o.value?o.value.availableLocales:Object.keys(u.value)},get modifiers(){return o.value?o.value.modifiers:v},get pluralRules(){return o.value?o.value.pluralRules:T},get isGlobal(){return o.value?o.value.isGlobal:!1},get missingWarn(){return o.value?o.value.missingWarn:m},set missingWarn(y){o.value&&(o.value.missingWarn=y)},get fallbackWarn(){return o.value?o.value.fallbackWarn:g},set fallbackWarn(y){o.value&&(o.value.missingWarn=y)},get fallbackRoot(){return o.value?o.value.fallbackRoot:C},set fallbackRoot(y){o.value&&(o.value.fallbackRoot=y)},get fallbackFormat(){return o.value?o.value.fallbackFormat:k},set fallbackFormat(y){o.value&&(o.value.fallbackFormat=y)},get warnHtmlMessage(){return o.value?o.value.warnHtmlMessage:I},set warnHtmlMessage(y){o.value&&(o.value.warnHtmlMessage=y)},get escapeParameter(){return o.value?o.value.escapeParameter:b},set escapeParameter(y){o.value&&(o.value.escapeParameter=y)},t:ae,getPostTranslationHandler:P,setPostTranslationHandler:Y,getMissingHandler:Se,setMissingHandler:Re,rt:pe,d:Xe,n:tt,tm:Ae,te:De,getLocaleMessage:pt,setLocaleMessage:B,mergeLocaleMessage:le,getDateTimeFormat:ve,setDateTimeFormat:F,mergeDateTimeFormat:ee,getNumberFormat:Q,setNumberFormat:ne,mergeNumberFormat:me};function w(y){y.locale.value=a.value,y.fallbackLocale.value=i.value,Object.keys(u.value).forEach(R=>{y.mergeLocaleMessage(R,u.value[R])}),Object.keys(f.value).forEach(R=>{y.mergeDateTimeFormat(R,f.value[R])}),Object.keys(d.value).forEach(R=>{y.mergeNumberFormat(R,d.value[R])}),y.escapeParameter=b,y.fallbackFormat=k,y.fallbackRoot=C,y.fallbackWarn=g,y.missingWarn=m,y.warnHtmlMessage=I}return Fi(()=>{if(e.proxy==null||e.proxy.$i18n==null)throw Ye(Ke.NOT_AVAILABLE_COMPOSITION_IN_LEGACY);const y=o.value=e.proxy.$i18n.__composer;t==="global"?(a.value=y.locale.value,i.value=y.fallbackLocale.value,u.value=y.messages.value,f.value=y.datetimeFormats.value,d.value=y.numberFormats.value):l&&w(y)}),_}const vh=["locale","fallbackLocale","availableLocales"],Da=["t","rt","d","n","tm","te"];function bh(e,t){const n=Object.create(null);return vh.forEach(l=>{const o=Object.getOwnPropertyDescriptor(t,l);if(!o)throw Ye(Ke.UNEXPECTED_ERROR);const r=Ve(o.value)?{get(){return o.value.value},set(a){o.value.value=a}}:{get(){return o.get&&o.get()}};Object.defineProperty(n,l,r)}),e.config.globalProperties.$i18n=n,Da.forEach(l=>{const o=Object.getOwnPropertyDescriptor(t,l);if(!o||!o.value)throw Ye(Ke.UNEXPECTED_ERROR);Object.defineProperty(e.config.globalProperties,`$${l}`,o)}),()=>{delete e.config.globalProperties.$i18n,Da.forEach(l=>{delete e.config.globalProperties[`$${l}`]})}}Yp();__INTLIFY_JIT_COMPILATION__?ma(Hp):ma(Vp);Ip(fp);Pp(Dc);if(__INTLIFY_PROD_DEVTOOLS__){const e=zt();e.__INTLIFY__=!0,yp(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const _h={key:0,class:"fixed inset-0 modal-overlay flex items-center justify-center z-[9999] p-4"},yh={class:"bg-white rounded-lg shadow-xl max-w-md w-full"},wh={class:"p-6"},xh={class:"flex items-center mb-4"},Eh={class:"text-xl font-semibold text-gray-900"},kh={class:"text-sm text-gray-500 mt-1"},Ch={class:"mb-6"},Sh={class:"block text-sm font-medium text-gray-700 mb-2"},Th=["placeholder"],Lh={key:0,class:"mt-2 text-sm text-red-600"},$h={class:"flex justify-end"},Nh=["disabled"],Ih=Oe({__name:"PasswordDialog",props:{visible:{type:Boolean}},emits:["confirm"],setup(e,{expose:t,emit:n}){const{t:s}=je(),l=e,o=n,r=q(""),a=q(""),i=q(!1),u=q(null);mt(()=>l.visible,d=>{d&&(r.value="",a.value="",i.value=!1,Rs(()=>{u.value?.focus()}))});function f(){i.value||!r.value.trim()||(i.value=!0,a.value="",o("confirm",r.value.trim()))}return t({setError:d=>{a.value=d,i.value=!1},reset:()=>{r.value="",a.value="",i.value=!1}}),(d,m)=>e.visible?(K(),Z("div",_h,[c("div",yh,[c("div",wh,[c("div",xh,[m[1]||(m[1]=c("div",{class:"flex-shrink-0 w-10 h-10 bg-red-100 rounded-full flex items-center justify-center mr-3"},[c("i",{class:"fas fa-lock text-red-600"})],-1)),c("div",null,[c("h2",Eh,E(d.$t("config.passwordRequired")),1),c("p",kh,E(d.$t("config.passwordRequiredHint")),1)])]),c("div",Ch,[c("label",Sh,E(d.$t("config.token")),1),Fe(c("input",{ref_key:"passwordInput",ref:u,"onUpdate:modelValue":m[0]||(m[0]=g=>r.value=g),type:"password",maxlength:"256",class:"w-full p-3 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",placeholder:d.$t("config.tokenPlaceholder"),onKeyup:ql(f,["enter"])},null,40,Th),[[ot,r.value]]),a.value?(K(),Z("p",Lh,E(a.value),1)):se("",!0)]),c("div",$h,[c("button",{onClick:f,disabled:i.value||!r.value.trim(),class:"px-6 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-lg transition-colors disabled:opacity-50 disabled:cursor-not-allowed"},E(i.value?d.$t("config.verifying"):d.$t("common.confirm")),9,Nh)])])])])):se("",!0)}});function Ph(e){if(!e)return"";let t=e.trim();const n=t.match(/《([^》]+)》/);n&&(t=n[1]);const s=t.match(/【([^】]+)】/);if(s&&(t=s[1]),t.includes(" - "))t=t.split(" - ")[0].trim();else if(t.includes("-")){const l=t.split("-");l.length===2&&!/^\d{4}-\d{2}-\d{2}/.test(t)&&(t=l[0].trim())}return t=t.replace(/\s*-\s*(在线观看|免费观看|高清|HD|1080P|720P|4K)/gi,""),t=t.replace(/\s*\[.*?\]/g,""),t=t.replace(/\s*\(.*?\)/g,""),t=t.replace(/\s*(完整版|未删减版|国语版|粤语版|中字|无字幕|高清版|标清版)$/gi,""),t=t.replace(/\s+/g," ").trim(),t||e.trim()}function Oa(e){return String(e||"").split(`
|
|
4
|
+
`).map(t=>{const n=t.split(/[\s|$]+/).map(o=>o.trim());let s=n[0],l=n[1]||"";return l.startsWith("http")&&([l,s]=[s,l]),{url:s,name:l}}).filter(t=>t.url.startsWith("http"))}const Ah={class:"bg-white rounded-lg p-6 max-w-4xl w-full max-h-[90vh] overflow-y-auto"},Dh={class:"flex justify-between items-center mb-4"},Oh={class:"text-xl text-center w-full font-semibold"},Rh={class:"text-left"},Mh={class:"flex flex-row gap-4"},Fh=["placeholder"],Uh={class:"flex flex-row gap-1"},Vh=["disabled"],Hh={class:"mt-4"},Wh=["placeholder"],jh={class:"mt-1 text-sm text-gray-500"},Bh={class:"mt-4"},Gh={class:"block text-sm font-bold text-gray-700 mb-1"},Kh=["placeholder"],Yh={class:"mt-4"},qh={class:"flex flex-row gap-2 items-center"},Xh={class:"block text-sm font-bold text-gray-700 mb-1"},zh=["placeholder"],Qh={class:"ml-2 mt-1 text-sm text-gray-500"},Jh={class:"mt-4 flex flex-row gap-2 items-center"},Zh={class:"block text-sm font-bold text-gray-700 mb-1"},eg=["placeholder"],tg={class:"mt-4"},ng={class:"block text-sm font-bold text-gray-700 mb-1"},sg=["placeholder"],og={class:"mt-4"},lg={class:"block text-sm font-bold text-gray-700 mb-1"},rg=["placeholder"],ag={class:"flex justify-end space-x-4 mt-6"},ig=["disabled"],rr=Oe({__name:"NewDownloadDialog",props:{visible:{type:Boolean},initialData:{}},emits:["close"],setup(e,{emit:t}){const{t:n}=je(),s=e,l=t,o=ss(),r=Mn(),a=q(""),i=q(""),u=q(""),f=q(o.config.saveDir||""),d=q(""),m=q(""),g=q(""),C=q(!1),k=q(!1);mt(()=>s.visible,b=>{if(b){if(f.value=o.config.saveDir||"",s.initialData&&s.initialData.url){const v=s.initialData.url;if(v.includes("|")){const T=Oa(v).map(({url:$,name:S})=>S?`${$} | ${Ph(S)}`:$);i.value=T.join(`
|
|
5
|
+
`)}else i.value=v}}else a.value="",i.value="",u.value="",d.value="",m.value="",g.value=""});async function N(){const b=a.value.trim();if(!/^https?:/.test(b)){be({text:n("toast.enterValidUrl"),type:"error"});return}C.value=!0;try{const v=await am(b,m.value.trim(),g.value.trim()||void 0);v.code===0&&Array.isArray(v.data)&&v.data.length>0?(i.value=v.data.map(T=>T.join(" | ")).join(`
|
|
6
|
+
`),be({text:v.message||n("toast.extractSuccess",{count:v.data.length}),type:"success"})):be({text:v.message||n("toast.extractFailed"),type:"error"})}catch(v){be({text:n("toast.extractError",{error:v instanceof Error?v.message:n("error.unknownError")}),type:"error"})}finally{C.value=!1}}function O(){l("close")}async function I(){const b=i.value.trim();if(!b){be({text:n("newDownload.enterM3u8Link"),type:"error"});return}const v=Oa(b);if(!v.length){be({text:n("newDownload.enterValidM3u8Link"),type:"error"});return}let T=f.value;v.length>1&&u.value&&!T.includes(u.value)&&(T||(T=o.config.saveDir),T=T.replace(/\/?$/,"")+"/"+u.value);const $=v.map((S,L)=>({url:S.url,filename:S.name||(u.value?`${u.value}${v.length>1?n("taskItem.episode",{index:L+1}):""}`:""),saveDir:T,headers:m.value.trim()||void 0,ignoreSegments:d.value.trim()||void 0}));k.value=!0;try{$.forEach(L=>{/\.html?$/.test(L.url)||r.updateTask(L.url,{status:"resume",progress:0,speed:0,remainingTime:0,size:0})});const S=await om($);S.code?be({text:S.message||n("toast.downloadFailed"),type:"error"}):(be({text:S.message||n("toast.downloadStarted"),type:"success"}),O())}catch(S){console.error("批量下载失败:",S),be({text:`${n("toast.downloadFailed")}: ${S instanceof Error?S.message:n("error.unknownError")}`,type:"error"})}finally{k.value=!1}}return(b,v)=>e.visible?(K(),Z("div",{key:0,class:"fixed inset-0 modal-overlay flex items-center justify-center z-50",onClick:gn(O,["self"])},[c("div",Ah,[c("div",Dh,[c("h2",Oh,E(b.$t("newDownload.title")),1),c("button",{onClick:O,class:"text-gray-500 hover:text-gray-700"},[...v[7]||(v[7]=[c("i",{class:"fas fa-times"},null,-1)])])]),c("div",Rh,[c("div",Mh,[Fe(c("input",{"onUpdate:modelValue":v[0]||(v[0]=T=>a.value=T),type:"text",placeholder:b.$t("newDownload.playUrl"),autocomplete:"off",class:"flex-1 border border-gray-300 rounded px-3 py-2 focus:outline-none focus:ring-2 focus:ring-blue-400"},null,8,Fh),[[ot,a.value]]),c("div",Uh,[c("button",{onClick:N,disabled:C.value,class:"px-2 py-1 bg-blue-600 text-white rounded hover:bg-blue-700 focus:outline-none disabled:opacity-50"},E(C.value?b.$t("newDownload.extracting"):b.$t("newDownload.extract")),9,Vh)])]),c("div",Hh,[Fe(c("input",{"onUpdate:modelValue":v[1]||(v[1]=T=>g.value=T),class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:b.$t("newDownload.subUrlRegex")},null,8,Wh),[[ot,g.value]]),c("p",jh,E(b.$t("newDownload.subUrlRegexHint")),1)]),c("div",Bh,[c("label",Gh,E(b.$t("newDownload.videoLinks")),1),Fe(c("textarea",{"onUpdate:modelValue":v[2]||(v[2]=T=>i.value=T),class:"w-full p-2 border rounded-lg focus:ring-blue-500",rows:"3",placeholder:b.$t("newDownload.videoLinksPlaceholder")},null,8,Kh),[[ot,i.value]])]),c("div",Yh,[c("div",qh,[c("label",Xh,E(b.$t("newDownload.videoName")),1),Fe(c("input",{"onUpdate:modelValue":v[3]||(v[3]=T=>u.value=T),class:"flex-1 p-2 border rounded-lg focus:border-blue-500",placeholder:b.$t("newDownload.videoNamePlaceholder")},null,8,zh),[[ot,u.value]])]),c("p",Qh,E(b.$t("newDownload.videoNameHint")),1)]),c("div",Jh,[c("label",Zh,E(b.$t("newDownload.saveDir")),1),Fe(c("input",{"onUpdate:modelValue":v[4]||(v[4]=T=>f.value=T),class:"flex-1 p-2 border rounded-lg focus:ring-blue-500",placeholder:b.$t("newDownload.saveDirPlaceholder")},null,8,eg),[[ot,f.value]])]),c("div",tg,[c("label",ng,E(b.$t("newDownload.ignoreSegments")),1),Fe(c("input",{"onUpdate:modelValue":v[5]||(v[5]=T=>d.value=T),class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:b.$t("newDownload.ignoreSegmentsPlaceholder")},null,8,sg),[[ot,d.value]])]),c("div",og,[c("label",lg,E(b.$t("newDownload.headers")),1),Fe(c("textarea",{"onUpdate:modelValue":v[6]||(v[6]=T=>m.value=T),class:"w-full p-2 border rounded-lg focus:ring-blue-500",rows:"3",placeholder:b.$t("newDownload.headersPlaceholder")},null,8,rg),[[ot,m.value]])])]),c("div",ag,[c("button",{onClick:O,class:"px-6 py-2 text-gray-600 hover:bg-gray-100 rounded-lg border"},E(b.$t("common.cancel")),1),c("button",{onClick:I,disabled:k.value,class:"px-6 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-lg disabled:opacity-50 disabled:cursor-not-allowed"},E(k.value?b.$t("newDownload.submitting"):b.$t("newDownload.startDownload")),9,ig)])])])):se("",!0)}}),cg={id:"app"},ug=Oe({__name:"App",setup(e){const t=ss();let n=null;const s=q(!1),l=q(null),o=q(!1),r=q(void 0);function a(m){r.value=m,o.value=!0}hs("showGlobalNewDownload",a);function i(){o.value=!1,r.value=void 0}function u(){s.value=!0}Vt(async()=>{const m=localStorage.getItem("token")||"";m&&(t.token=m);try{await t.loadConfig()}catch(N){console.log("[App] 配置加载失败,使用本地 token:",N)}const g=t.token||localStorage.getItem("token")||"";g&&!t.token&&(t.token=g);const{connect:C,disconnect:k}=Jl(g,u);n=k,C()}),On(()=>{n&&n()});function f(){}async function d(m){if(!m.trim()){l.value?.setError("请输入访问密码");return}try{let g=m.trim();typeof window<"u"&&window.md5?g=window.md5(g).slice(0,8):g=btoa(g).replace(/[^a-zA-Z0-9]/g,"").slice(0,8),t.token=g,localStorage.setItem("token",g),um(g,!0,C=>{C?(s.value=!1,l.value?.reset()):l.value?.setError("密码错误,请重新输入")}),l.value?.reset()}catch(g){l.value?.setError("密码处理失败,请重试"),console.error("密码处理失败:",g)}}return(m,g)=>{const C=yf("router-view");return K(),Z("div",cg,[ye(C),ye(Ih,{visible:s.value,onClose:f,onConfirm:d,ref_key:"passwordDialogRef",ref:l},null,8,["visible"]),ye(rr,{visible:o.value,"initial-data":r.value,onClose:i},null,8,["visible","initial-data"])])}}}),fg={common:{save:"Save",cancel:"Cancel",confirm:"Confirm",delete:"Delete",edit:"Edit",close:"Close",ok:"OK",yes:"Yes",no:"No",loading:"Loading...",success:"Success",error:"Error",warning:"Warning",info:"Info",language:"Language",back:"Back",forward:"Forward",refresh:"Refresh"},layout:{title:"M3U8 Downloader",newDownload:"New Download",downloadManagement:"Download Management",webBrowser:"Web Browser",completed:"Completed",config:"Config Settings",about:"About",ariang:"Ariang"},download:{status:{resume:"Downloading",pending:"Pending",pause:"Paused",error:"Error",done:"Completed"},pause:"Pause",resume:"Resume",delete:"Delete",clearQueue:"Clear Queue",batchDownload:"Batch Download",selectAll:"Select All",selected:"Selected",noTasks:"No download tasks",taskDetail:"Task Detail"},newDownload:{title:"New Download",playUrl:"Enter video playback page URL to extract m3u8 download link",extract:"Extract",extracting:"Extracting...",subUrlRegex:"Playback page link pattern",subUrlRegexHint:"Used to accurately identify playback addresses from video list pages. Example: play/845-1-. Supports * wildcard (converted to .+)",videoLinks:"Video Links (one per line, supports m3u8 addresses and Douyin, Weibo, Pipixia video share links)",videoLinksPlaceholder:"Format: URL | Name(optional), Name | URL",videoName:"Video Name",videoNamePlaceholder:"Enter video name (optional)",videoNameHint:'If multiple links are entered, they will be named as "Video Name + Episode N"',saveDir:"Save Location",saveDirPlaceholder:"Enter save path",ignoreSegments:"Ignore Time Segments (for removing ad segments)",ignoreSegmentsPlaceholder:"Use - to separate start and end times, multiple separated by commas. Example: 0-10,20-100",headers:"Custom Headers",headersPlaceholder:`One per line (Weibo videos require Cookie), format: Key: Value. Example:
|
|
7
|
+
Referer: https://example.com
|
|
8
|
+
Cookie: token=123`,startDownload:"Start Download",submitting:"Submitting...",enterM3u8Link:"Please enter at least one M3U8 link",enterValidM3u8Link:"Please enter a valid M3U8 link"},webBrowser:{title:"Web Browser - Extract Download URLs",hideBrowser:"Hide Browser",showBrowser:"Show Browser",stop:"Stop",urlPlaceholder:"Enter webpage URL, will automatically extract m3u8 and mp4 video links from the page",load:"Load",loading:"Loading...",foundVideos:"Found {count} video links",clearList:"Clear List",download:"Download",noVideos:"No video links extracted yet, please wait for page to load or try another webpage",enterUrl:"Please enter webpage URL",enterValidUrl:"Please enter a valid webpage URL (starting with http:// or https://)",electronOnly:"This feature is only available in Electron client",pageLoadComplete:"Page load complete, found {count} video links",pageLoadCompleteNoVideos:"Page load complete, but no video links found",newVideoFound:"New video link found: {title}",selectAtLeastOne:"Please select at least one video link",source:"Source",unnamedVideo:"Unnamed Video"},error:{unauthorized:"Unauthorized access",downloadFailed:"Download failed",requestFailed:"Request failed",unknownError:"Unknown error",noLocalFile:"No local file found"},taskList:{title:"Download Tasks",new:"New",pauseSelected:"Pause Selected",resumeSelected:"Resume Selected",deleteSelected:"Delete Selected",pauseAll:"Pause All",resumeAll:"Resume All",clearQueue:"Clear Queue",searchPlaceholder:"Search task name or URL",searchLabel:"Search tasks",filterByStatus:"Filter by status",clearFilters:"Clear filters",all:"All",status:{resume:"Downloading",pending:"Pending",pause:"Paused",error:"Error",done:"Completed"},selectAll:"Select All/Toggle",selected:"Selected",total:"Total",pending:"Pending",downloading:"Downloading"},taskItem:{episode:"Episode {index}",play:"Play",localPlay:"Local Play",preview:"Preview",detail:"Detail",retry:"Retry",selectTask:"Select task: {name}",pause:"Pause",resume:"Resume",delete:"Delete",duration:"Duration",size:"Size",segments:"Segments",remaining:"Remaining",video:"Video"},config:{title:"Config Settings",downloadSettings:"Download Settings",threadNum:"Concurrent download threads per task",threadNumPlaceholder:"Enter thread count (1-16)",threadNumHint:"Recommended not more than 8, too many concurrent requests to a single server may result in IP ban",maxDownloads:"Maximum concurrent downloads",maxDownloadsPlaceholder:"Enter max concurrent downloads (1-10)",maxDownloadsHint:"Maximum number of concurrent download tasks, default is 3",saveDir:"Video save directory",saveDirPlaceholder:"Enter save directory path",saveDirHint:"Default is downloads folder in current directory",delCache:"Delete ts segment cache after download completes",delCacheLabel:"Delete segment files",delCacheHint:"Saving temporary files can identify cache when re-downloading",convert:"Convert format after download completes",convertLabel:"Merge and convert to MP4/TS file",convertHint:"Automatically merge and convert to MP4 format after download completes",showPreview:"Show preview button",showPreviewLabel:"Show preview button in download list",showLocalPlay:"Show local play button",showLocalPlayLabel:"Show local play button in download list",ffmpegPath:"ffmpeg executable file path",ffmpegPathPlaceholder:"Leave empty to use ffmpeg from system PATH",ffmpegPathHint:"Specify the full path to the ffmpeg executable file. If left empty, will try to use ffmpeg from system PATH environment variable",save:"Save Config",saveSuccess:"Config saved successfully",saveFailed:"Config save failed",localConfig:"Local Settings",token:"Access Password",tokenPlaceholder:"Enter access password",tokenHint:"If the server has set an access password (token), please enter it here",updateLocalConfig:"Update Local Config",localConfigUpdated:"Local config updated",enterPassword:"Please enter access password",passwordRequired:"Access Password Required",passwordRequiredHint:"Please enter the correct access password to continue",passwordError:"Password error, please re-enter",passwordProcessFailed:"Password processing failed, please try again",configUpdated:"Config updated",verifying:"Verifying..."},about:{title:"About",projectInfo:"Project Info",license:"License",author:"Author",github:"GitHub",issues:"Issues",currentVersion:"Current Version",checkVersion:"Check for Updates",newVersionFound:"New version found! [{version}]",projectDescription:"Project Description",projectDescriptionText:"is a powerful m3u8 file video batch download tool that supports multi-threaded downloads, play while downloading, cache resume, and other features.",features:"Main Features",feature1:"Multi-threaded download: Multi-threaded download using thread pool mode",feature2:"Play while downloading: Support online playback using downloaded ts cache files",feature3:"Batch download: Support batch download of multiple m3u8 addresses",feature4:"Cache resume: Failed downloads retain cache, retry only downloads failed segments",feature5:"Encryption support: Support common AES encrypted video stream decryption",feature6:"Format conversion: Support automatic conversion to mp4 (requires ffmpeg installation)",feature7:"Search function: Support specifying collection site standard API for command-line interactive search and download",feature8:"WebUI: Provides download center, supports starting as webui service for download management",installation:"Installation",globalInstall:"Global install:",useNpx:"Use npx:",docker:"Docker Deployment",dockerCommand:"Run with Docker command:",dockerCompose:"Run with docker-compose:",dockerDeployComplete:"After deployment, visit {url} to use the WebUI interface.",latestVersion:"Already latest version, no update needed [{version}]",newVersionAvailable:"New version found [{version}], please visit {url} to download the latest version",versionCheckFailed:"Version check failed: {error}"},confirm:{play:"Confirm Play",playError:"Error: {error}",playConfirmMessage:`This task status is abnormal and may not play normally.
|
|
9
|
+
|
|
10
|
+
Are you sure you want to continue playing?`,delete:"Confirm Delete",deleteMessage:"Are you sure you want to delete {count} selected download tasks?",deleteCache:"Delete cache files",deleteVideo:"Delete video files"},toast:{downloadStarted:"Batch download started",downloadFailed:"Download failed",pauseSuccess:"Download paused",resumeSuccess:"Download resumed",deleteSuccess:"Selected downloads deleted",clearQueueSuccess:"Download queue cleared",clearQueueFailed:"Failed to clear queue",wsConnected:"WebSocket connected",passwordVerified:"Password verified, connection established",extractSuccess:"Extraction complete! Found {count} addresses",extractFailed:"Extraction failed, no M3U8 address found",extractError:"Extraction failed: {error}",enterValidUrl:"Please enter a valid URL address",copySuccess:"Copied to clipboard",copyFailed:"Copy failed"},emptyState:{noTasks:"No download tasks",addTask:"Add Download Task"},taskDetail:{title:"Task Detail",name:"Name",status:"Status",progress:"Progress",avgSpeed:"Avg Speed",size:"Size",segments:"Segments",threadNum:"Threads",duration:"Duration",startTime:"Start Time",endTime:"End Time",remainingTime:"Remaining",downloadUrl:"Download URL",saveLocation:"Save Location",relatedInfo:"Related Info",copy:"Copy",close:"Close"},completedList:{title:"Completed Tasks",total:"Total {count} items",sortBy:"Sort by:",sortStartTime:"Start Time",sortEndTime:"End Time",sortName:"Name",sortSize:"Size",sortSaveDir:"Save Location",ascending:"Ascending",descending:"Descending",searchPlaceholder:"Search task name or URL",action:"Action",taskName:"Task Name",fileSize:"File Size",startTime:"Start Time",endTime:"End Time",viewDetail:"View Detail",play:"Play",delete:"Delete",noCompletedTasks:"No completed tasks",selected:"Selected {count} items",deleteSelected:"Delete Selected"},deleteConfirm:{title:"Confirm Delete",message:"Are you sure you want to delete {count} selected tasks?",deleteCache:"Also delete downloaded cache files",deleteVideo:"Also delete downloaded video files",cancel:"Cancel",confirm:"Confirm Delete"}},dg={common:{save:"保存",cancel:"取消",confirm:"确认",delete:"删除",edit:"编辑",close:"关闭",ok:"确定",yes:"是",no:"否",loading:"加载中...",success:"成功",error:"错误",warning:"警告",info:"信息",language:"语言",back:"后退",forward:"前进",refresh:"刷新"},layout:{title:"M3U8 下载器",newDownload:"新建下载",downloadManagement:"下载管理",webBrowser:"网页浏览",completed:"已完成",config:"配置设置",about:"关于项目",ariang:"Ariang"},download:{status:{resume:"下载中",pending:"等待中",pause:"已暂停",error:"错误",done:"已完成"},pause:"暂停",resume:"恢复",delete:"删除",clearQueue:"清空队列",batchDownload:"批量下载",selectAll:"全选",selected:"已选择",noTasks:"暂无下载任务",taskDetail:"任务详情"},newDownload:{title:"新建下载",playUrl:"输入视频播放页地址,尝试提取m3u8下载链接",extract:"提取",extracting:"解析中...",subUrlRegex:"播放页链接特征规则",subUrlRegexHint:"用于从视频列表页准确识别播放地址。如:play/845-1-。支持 * 通配符(会被转换为 .+)",videoLinks:"视频链接(每行一个,支持m3u8地址及抖音、微博、皮皮虾视频分享链接)",videoLinksPlaceholder:"格式: URL | 名称(可选)、名称 | URL",videoName:"视频名称",videoNamePlaceholder:"请输入视频名称(可选)",videoNameHint:'若输入多个链接,将依次以"视频名称+第N集"命名',saveDir:"保存位置",saveDirPlaceholder:"请输入保存路径",ignoreSegments:"删除时间片段(适用于移除广告片段的情况)",ignoreSegmentsPlaceholder:"以-分割起止时间,多个以逗号分隔。示例:0-10,20-100",headers:"自定义请求头",headersPlaceholder:`每行一个(微博视频须设置 Cookie),格式:Key: Value。例如:
|
|
11
|
+
Referer: https://example.com
|
|
12
|
+
Cookie: token=123`,startDownload:"开始下载",submitting:"提交中...",enterM3u8Link:"请输入至少一个 M3U8 链接",enterValidM3u8Link:"请输入正确的 M3U8 链接"},webBrowser:{title:"网页浏览提取下载地址",hideBrowser:"隐藏浏览器",showBrowser:"显示浏览器",stop:"停止",urlPlaceholder:"输入网页地址,将自动提取页面中的 m3u8 和 mp4 视频链接",load:"加载",loading:"加载中...",foundVideos:"找到 {count} 个视频链接",clearList:"清空列表",download:"下载",noVideos:"暂无提取到的视频链接,请等待页面加载完成或尝试其他网页",enterUrl:"请输入网页地址",enterValidUrl:"请输入正确的网页地址(以 http:// 或 https:// 开头)",electronOnly:"此功能仅在 Electron 客户端中可用",pageLoadComplete:"页面加载完成,共发现 {count} 个视频链接",pageLoadCompleteNoVideos:"页面加载完成,但未发现视频链接",newVideoFound:"发现新的视频链接: {title}",selectAtLeastOne:"请至少选择一个视频链接",source:"来源",unnamedVideo:"未命名视频"},error:{unauthorized:"未授权,禁止访问",downloadFailed:"下载失败",requestFailed:"请求失败",unknownError:"未知错误",noLocalFile:"未找到本地文件"},taskList:{title:"下载任务",new:"新建",pauseSelected:"暂停选中",resumeSelected:"开始选中",deleteSelected:"删除选中",pauseAll:"全部暂停",resumeAll:"全部开始",clearQueue:"清空队列",searchPlaceholder:"搜索任务名称或URL",searchLabel:"搜索任务",filterByStatus:"按状态筛选",clearFilters:"清除筛选条件",all:"全部",status:{resume:"下载中",pending:"等待中",pause:"已暂停",error:"异常",done:"已完成"},selectAll:"全选/反选",selected:"已选",total:"总数",pending:"等待中",downloading:"下载中"},taskItem:{episode:"第{index}集",play:"播放",localPlay:"边下边播",preview:"预览",detail:"详情",retry:"重试",selectTask:"选择任务:{name}",pause:"暂停",resume:"继续",delete:"删除",duration:"时长",size:"大小",segments:"分片",remaining:"剩余",video:"视频"},config:{title:"配置设置",downloadSettings:"下载设置",threadNum:"单任务并发下载线程数",threadNumPlaceholder:"请输入线程数(1-16)",threadNumHint:"建议不超过 8 个,对单个服务器的并发请求数过多可能会导致被封 IP",maxDownloads:"最多同时下载视频数",maxDownloadsPlaceholder:"请输入最大并发下载数(1-10)",maxDownloadsHint:"最多同时下载任务数量,默认为 3",saveDir:"视频保存目录",saveDirPlaceholder:"请输入保存目录路径",saveDirHint:"默认为当前目录下 downloads 文件夹",delCache:"下载完成后删除ts分片缓存",delCacheLabel:"删除分片文件",delCacheHint:"保存临时文件可以在重复下载时识别缓存",convert:"下载完成后转换格式",convertLabel:"合并转换为 MP4/TS 文件",convertHint:"下载完成后自动合并转换为 MP4 格式",showPreview:"显示预览按钮",showPreviewLabel:"在下载列表中显示预览按钮",showLocalPlay:"显示边下边播按钮",showLocalPlayLabel:"在下载列表中显示边下边播按钮",ffmpegPath:"ffmpeg 可执行文件路径",ffmpegPathPlaceholder:"留空则使用系统 PATH 中的 ffmpeg",ffmpegPathHint:"指定 ffmpeg 可执行文件的完整路径。如果留空,则尝试使用系统 PATH 环境变量中的 ffmpeg",save:"保存配置",saveSuccess:"配置保存成功",saveFailed:"配置保存失败",localConfig:"本地设置",token:"访问密码",tokenPlaceholder:"请输入访问密码",tokenHint:"若服务端设置了访问密码(token),请在此输入",updateLocalConfig:"更新本地配置",localConfigUpdated:"本地配置已更新",enterPassword:"请输入访问密码",passwordRequired:"需要访问密码",passwordRequiredHint:"请输入正确的访问密码以继续",passwordError:"密码错误,请重新输入",passwordProcessFailed:"密码处理失败,请重试",configUpdated:"配置已更新",verifying:"验证中..."},about:{title:"关于项目",projectInfo:"项目信息",license:"许可证",author:"作者",github:"GitHub",issues:"问题反馈",currentVersion:"当前版本",checkVersion:"检测新版本",newVersionFound:"发现新版本![{version}]",projectDescription:"项目简介",projectDescriptionText:"是一个功能强大的 m3u8 文件视频批量下载工具,支持多线程下载、边下边播、缓存续传等特性。",features:"主要特性",feature1:"多线程下载:采用线程池模式的多线程下载",feature2:"边下边播模式:支持使用已下载的 ts 缓存文件在线播放",feature3:"批量下载:支持指定多个 m3u8 地址批量下载",feature4:"缓存续传:下载失败会保留缓存,重试时只下载失败的片段",feature5:"加密支持:支持常见的 AES 加密视频流解密",feature6:"格式转换:支持自动转换为 mp4(需安装 ffmpeg)",feature7:"搜索功能:支持指定采集站标准 API,以命令行交互的方式搜索和下载",feature8:"WebUI:提供下载中心,支持启动为 webui 服务方式进行下载管理",installation:"安装使用",globalInstall:"全局安装:",useNpx:"使用 npx:",docker:"Docker 部署",dockerCommand:"使用 Docker 命令运行:",dockerCompose:"使用 docker-compose 运行:",dockerDeployComplete:"部署完成后,访问 {url} 即可使用 WebUI 界面。",latestVersion:"已是最新版本,无需更新[{version}]",newVersionAvailable:"发现新版本[{version}],请前往 {url} 下载最新版本",versionCheckFailed:"版本检查失败:{error}"},confirm:{play:"确认播放",playError:"错误信息:{error}",playConfirmMessage:`该任务状态为异常,可能无法正常播放。
|
|
13
|
+
|
|
14
|
+
确定要继续播放吗?`,delete:"确认删除",deleteMessage:"确定要删除选中的 {count} 个下载任务吗?",deleteCache:"删除缓存文件",deleteVideo:"删除视频文件"},toast:{downloadStarted:"批量下载已开始",downloadFailed:"下载失败",pauseSuccess:"已暂停下载",resumeSuccess:"已恢复下载",deleteSuccess:"已删除选中的下载",clearQueueSuccess:"已清空下载队列",clearQueueFailed:"清空队列失败",wsConnected:"ws连接成功",passwordVerified:"密码验证成功,连接已建立",extractSuccess:"解析完成!获取到 {count} 个地址",extractFailed:"解析失败,未找到 M3U8 地址",extractError:"解析失败: {error}",enterValidUrl:"请输入正确的 URL 地址",copySuccess:"已复制到剪贴板",copyFailed:"复制失败"},emptyState:{noTasks:"暂无下载任务",addTask:"添加下载任务"},taskDetail:{title:"任务详情",name:"名称",status:"状态",progress:"进度",avgSpeed:"平均速度",size:"大小",segments:"分片",threadNum:"并发线程",duration:"时长",startTime:"开始时间",endTime:"结束时间",remainingTime:"预估还需",downloadUrl:"下载地址",saveLocation:"保存位置",relatedInfo:"相关信息",copy:"复制",close:"关闭"},completedList:{title:"已完成任务",total:"共 {count} 项",sortBy:"排序方式:",sortStartTime:"开始时间",sortEndTime:"结束时间",sortName:"名称",sortSize:"大小",sortSaveDir:"保存位置",ascending:"升序",descending:"降序",searchPlaceholder:"搜索任务名称或URL地址",action:"操作",taskName:"任务名称",fileSize:"文件大小",startTime:"开始时间",endTime:"结束时间",viewDetail:"查看详情",play:"播放",delete:"删除",noCompletedTasks:"暂无已完成的任务",selected:"已选择 {count} 项",deleteSelected:"删除选中"},deleteConfirm:{title:"确认删除",message:"确定要删除选中的 {count} 个任务吗?",deleteCache:"同时删除已下载的缓存文件",deleteVideo:"同时删除已下载的视频文件",cancel:"取消",confirm:"确认删除"}},kl={zh:dg,en:fg};function mg(){if(typeof window>"u")return"en";const e=localStorage.getItem("language");if(e&&e in kl)return e;const n=(navigator.language||navigator.userLanguage||"en").toLowerCase().split("-")[0];return n in kl?n:"en"}const pg=ih({legacy:!1,locale:mg(),fallbackLocale:"en",messages:kl});const jn=typeof document<"u";function Zc(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function hg(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&Zc(e.default)}const Ee=Object.assign;function Qo(e,t){const n={};for(const s in t){const l=t[s];n[s]=Nt(l)?l.map(e):e(l)}return n}const bs=()=>{},Nt=Array.isArray;function Ra(e,t){const n={};for(const s in e)n[s]=s in t?t[s]:e[s];return n}const eu=/#/g,gg=/&/g,vg=/\//g,bg=/=/g,_g=/\?/g,tu=/\+/g,yg=/%5B/g,wg=/%5D/g,nu=/%5E/g,xg=/%60/g,su=/%7B/g,Eg=/%7C/g,ou=/%7D/g,kg=/%20/g;function ar(e){return e==null?"":encodeURI(""+e).replace(Eg,"|").replace(yg,"[").replace(wg,"]")}function Cg(e){return ar(e).replace(su,"{").replace(ou,"}").replace(nu,"^")}function Cl(e){return ar(e).replace(tu,"%2B").replace(kg,"+").replace(eu,"%23").replace(gg,"%26").replace(xg,"`").replace(su,"{").replace(ou,"}").replace(nu,"^")}function Sg(e){return Cl(e).replace(bg,"%3D")}function Tg(e){return ar(e).replace(eu,"%23").replace(_g,"%3F")}function Lg(e){return Tg(e).replace(vg,"%2F")}function Is(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}const $g=/\/$/,Ng=e=>e.replace($g,"");function Jo(e,t,n="/"){let s,l={},o="",r="";const a=t.indexOf("#");let i=t.indexOf("?");return i=a>=0&&i>a?-1:i,i>=0&&(s=t.slice(0,i),o=t.slice(i,a>0?a:t.length),l=e(o.slice(1))),a>=0&&(s=s||t.slice(0,a),r=t.slice(a,t.length)),s=Dg(s??t,n),{fullPath:s+o+r,path:s,query:l,hash:Is(r)}}function Ig(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function Ma(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function Pg(e,t,n){const s=t.matched.length-1,l=n.matched.length-1;return s>-1&&s===l&&Zn(t.matched[s],n.matched[l])&&lu(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function Zn(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function lu(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!Ag(e[n],t[n]))return!1;return!0}function Ag(e,t){return Nt(e)?Fa(e,t):Nt(t)?Fa(t,e):e===t}function Fa(e,t){return Nt(t)?e.length===t.length&&e.every((n,s)=>n===t[s]):e.length===1&&e[0]===t}function Dg(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),s=e.split("/"),l=s[s.length-1];(l===".."||l===".")&&s.push("");let o=n.length-1,r,a;for(r=0;r<s.length;r++)if(a=s[r],a!==".")if(a==="..")o>1&&o--;else break;return n.slice(0,o).join("/")+"/"+s.slice(r).join("/")}const on={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};let Sl=(function(e){return e.pop="pop",e.push="push",e})({}),Zo=(function(e){return e.back="back",e.forward="forward",e.unknown="",e})({});function Og(e){if(!e)if(jn){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),Ng(e)}const Rg=/^[^#]+#/;function Mg(e,t){return e.replace(Rg,"#")+t}function Fg(e,t){const n=document.documentElement.getBoundingClientRect(),s=e.getBoundingClientRect();return{behavior:t.behavior,left:s.left-n.left-(t.left||0),top:s.top-n.top-(t.top||0)}}const No=()=>({left:window.scrollX,top:window.scrollY});function Ug(e){let t;if("el"in e){const n=e.el,s=typeof n=="string"&&n.startsWith("#"),l=typeof n=="string"?s?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!l)return;t=Fg(l,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function Ua(e,t){return(history.state?history.state.position-t:-1)+e}const Tl=new Map;function Vg(e,t){Tl.set(e,t)}function Hg(e){const t=Tl.get(e);return Tl.delete(e),t}function Wg(e){return typeof e=="string"||e&&typeof e=="object"}function ru(e){return typeof e=="string"||typeof e=="symbol"}let Ue=(function(e){return e[e.MATCHER_NOT_FOUND=1]="MATCHER_NOT_FOUND",e[e.NAVIGATION_GUARD_REDIRECT=2]="NAVIGATION_GUARD_REDIRECT",e[e.NAVIGATION_ABORTED=4]="NAVIGATION_ABORTED",e[e.NAVIGATION_CANCELLED=8]="NAVIGATION_CANCELLED",e[e.NAVIGATION_DUPLICATED=16]="NAVIGATION_DUPLICATED",e})({});const au=Symbol("");Ue.MATCHER_NOT_FOUND+"",Ue.NAVIGATION_GUARD_REDIRECT+"",Ue.NAVIGATION_ABORTED+"",Ue.NAVIGATION_CANCELLED+"",Ue.NAVIGATION_DUPLICATED+"";function es(e,t){return Ee(new Error,{type:e,[au]:!0},t)}function Gt(e,t){return e instanceof Error&&au in e&&(t==null||!!(e.type&t))}const jg=["params","query","hash"];function Bg(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;const t={};for(const n of jg)n in e&&(t[n]=e[n]);return JSON.stringify(t,null,2)}function Gg(e){const t={};if(e===""||e==="?")return t;const n=(e[0]==="?"?e.slice(1):e).split("&");for(let s=0;s<n.length;++s){const l=n[s].replace(tu," "),o=l.indexOf("="),r=Is(o<0?l:l.slice(0,o)),a=o<0?null:Is(l.slice(o+1));if(r in t){let i=t[r];Nt(i)||(i=t[r]=[i]),i.push(a)}else t[r]=a}return t}function Va(e){let t="";for(let n in e){const s=e[n];if(n=Sg(n),s==null){s!==void 0&&(t+=(t.length?"&":"")+n);continue}(Nt(s)?s.map(l=>l&&Cl(l)):[s&&Cl(s)]).forEach(l=>{l!==void 0&&(t+=(t.length?"&":"")+n,l!=null&&(t+="="+l))})}return t}function Kg(e){const t={};for(const n in e){const s=e[n];s!==void 0&&(t[n]=Nt(s)?s.map(l=>l==null?null:""+l):s==null?s:""+s)}return t}const Yg=Symbol(""),Ha=Symbol(""),Io=Symbol(""),ir=Symbol(""),Ll=Symbol("");function is(){let e=[];function t(s){return e.push(s),()=>{const l=e.indexOf(s);l>-1&&e.splice(l,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function cn(e,t,n,s,l,o=r=>r()){const r=s&&(s.enterCallbacks[l]=s.enterCallbacks[l]||[]);return()=>new Promise((a,i)=>{const u=m=>{m===!1?i(es(Ue.NAVIGATION_ABORTED,{from:n,to:t})):m instanceof Error?i(m):Wg(m)?i(es(Ue.NAVIGATION_GUARD_REDIRECT,{from:t,to:m})):(r&&s.enterCallbacks[l]===r&&typeof m=="function"&&r.push(m),a())},f=o(()=>e.call(s&&s.instances[l],t,n,u));let d=Promise.resolve(f);e.length<3&&(d=d.then(u)),d.catch(m=>i(m))})}function el(e,t,n,s,l=o=>o()){const o=[];for(const r of e)for(const a in r.components){let i=r.components[a];if(!(t!=="beforeRouteEnter"&&!r.instances[a]))if(Zc(i)){const u=(i.__vccOpts||i)[t];u&&o.push(cn(u,n,s,r,a,l))}else{let u=i();o.push(()=>u.then(f=>{if(!f)throw new Error(`Couldn't resolve component "${a}" at "${r.path}"`);const d=hg(f)?f.default:f;r.mods[a]=f,r.components[a]=d;const m=(d.__vccOpts||d)[t];return m&&cn(m,n,s,r,a,l)()}))}}return o}function qg(e,t){const n=[],s=[],l=[],o=Math.max(t.matched.length,e.matched.length);for(let r=0;r<o;r++){const a=t.matched[r];a&&(e.matched.find(u=>Zn(u,a))?s.push(a):n.push(a));const i=e.matched[r];i&&(t.matched.find(u=>Zn(u,i))||l.push(i))}return[n,s,l]}let Xg=()=>location.protocol+"//"+location.host;function iu(e,t){const{pathname:n,search:s,hash:l}=t,o=e.indexOf("#");if(o>-1){let r=l.includes(e.slice(o))?e.slice(o).length:1,a=l.slice(r);return a[0]!=="/"&&(a="/"+a),Ma(a,"")}return Ma(n,e)+s+l}function zg(e,t,n,s){let l=[],o=[],r=null;const a=({state:m})=>{const g=iu(e,location),C=n.value,k=t.value;let N=0;if(m){if(n.value=g,t.value=m,r&&r===C){r=null;return}N=k?m.position-k.position:0}else s(g);l.forEach(O=>{O(n.value,C,{delta:N,type:Sl.pop,direction:N?N>0?Zo.forward:Zo.back:Zo.unknown})})};function i(){r=n.value}function u(m){l.push(m);const g=()=>{const C=l.indexOf(m);C>-1&&l.splice(C,1)};return o.push(g),g}function f(){if(document.visibilityState==="hidden"){const{history:m}=window;if(!m.state)return;m.replaceState(Ee({},m.state,{scroll:No()}),"")}}function d(){for(const m of o)m();o=[],window.removeEventListener("popstate",a),window.removeEventListener("pagehide",f),document.removeEventListener("visibilitychange",f)}return window.addEventListener("popstate",a),window.addEventListener("pagehide",f),document.addEventListener("visibilitychange",f),{pauseListeners:i,listen:u,destroy:d}}function Wa(e,t,n,s=!1,l=!1){return{back:e,current:t,forward:n,replaced:s,position:window.history.length,scroll:l?No():null}}function Qg(e){const{history:t,location:n}=window,s={value:iu(e,n)},l={value:t.state};l.value||o(s.value,{back:null,current:s.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function o(i,u,f){const d=e.indexOf("#"),m=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+i:Xg()+e+i;try{t[f?"replaceState":"pushState"](u,"",m),l.value=u}catch(g){console.error(g),n[f?"replace":"assign"](m)}}function r(i,u){o(i,Ee({},t.state,Wa(l.value.back,i,l.value.forward,!0),u,{position:l.value.position}),!0),s.value=i}function a(i,u){const f=Ee({},l.value,t.state,{forward:i,scroll:No()});o(f.current,f,!0),o(i,Ee({},Wa(s.value,i,null),{position:f.position+1},u),!1),s.value=i}return{location:s,state:l,push:a,replace:r}}function Jg(e){e=Og(e);const t=Qg(e),n=zg(e,t.state,t.location,t.replace);function s(o,r=!0){r||n.pauseListeners(),history.go(o)}const l=Ee({location:"",base:e,go:s,createHref:Mg.bind(null,e)},t,n);return Object.defineProperty(l,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(l,"state",{enumerable:!0,get:()=>t.state.value}),l}function Zg(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),Jg(e)}let Pn=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({});var Be=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.ParamRegExp=2]="ParamRegExp",e[e.ParamRegExpEnd=3]="ParamRegExpEnd",e[e.EscapeNext=4]="EscapeNext",e})(Be||{});const ev={type:Pn.Static,value:""},tv=/[a-zA-Z0-9_]/;function nv(e){if(!e)return[[]];if(e==="/")return[[ev]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(g){throw new Error(`ERR (${n})/"${u}": ${g}`)}let n=Be.Static,s=n;const l=[];let o;function r(){o&&l.push(o),o=[]}let a=0,i,u="",f="";function d(){u&&(n===Be.Static?o.push({type:Pn.Static,value:u}):n===Be.Param||n===Be.ParamRegExp||n===Be.ParamRegExpEnd?(o.length>1&&(i==="*"||i==="+")&&t(`A repeatable param (${u}) must be alone in its segment. eg: '/:ids+.`),o.push({type:Pn.Param,value:u,regexp:f,repeatable:i==="*"||i==="+",optional:i==="*"||i==="?"})):t("Invalid state to consume buffer"),u="")}function m(){u+=i}for(;a<e.length;){if(i=e[a++],i==="\\"&&n!==Be.ParamRegExp){s=n,n=Be.EscapeNext;continue}switch(n){case Be.Static:i==="/"?(u&&d(),r()):i===":"?(d(),n=Be.Param):m();break;case Be.EscapeNext:m(),n=s;break;case Be.Param:i==="("?n=Be.ParamRegExp:tv.test(i)?m():(d(),n=Be.Static,i!=="*"&&i!=="?"&&i!=="+"&&a--);break;case Be.ParamRegExp:i===")"?f[f.length-1]=="\\"?f=f.slice(0,-1)+i:n=Be.ParamRegExpEnd:f+=i;break;case Be.ParamRegExpEnd:d(),n=Be.Static,i!=="*"&&i!=="?"&&i!=="+"&&a--,f="";break;default:t("Unknown state");break}}return n===Be.ParamRegExp&&t(`Unfinished custom RegExp for param "${u}"`),d(),r(),l}const ja="[^/]+?",sv={sensitive:!1,strict:!1,start:!0,end:!0};var ft=(function(e){return e[e._multiplier=10]="_multiplier",e[e.Root=90]="Root",e[e.Segment=40]="Segment",e[e.SubSegment=30]="SubSegment",e[e.Static=40]="Static",e[e.Dynamic=20]="Dynamic",e[e.BonusCustomRegExp=10]="BonusCustomRegExp",e[e.BonusWildcard=-50]="BonusWildcard",e[e.BonusRepeatable=-20]="BonusRepeatable",e[e.BonusOptional=-8]="BonusOptional",e[e.BonusStrict=.7000000000000001]="BonusStrict",e[e.BonusCaseSensitive=.25]="BonusCaseSensitive",e})(ft||{});const ov=/[.+*?^${}()[\]/\\]/g;function lv(e,t){const n=Ee({},sv,t),s=[];let l=n.start?"^":"";const o=[];for(const u of e){const f=u.length?[]:[ft.Root];n.strict&&!u.length&&(l+="/");for(let d=0;d<u.length;d++){const m=u[d];let g=ft.Segment+(n.sensitive?ft.BonusCaseSensitive:0);if(m.type===Pn.Static)d||(l+="/"),l+=m.value.replace(ov,"\\$&"),g+=ft.Static;else if(m.type===Pn.Param){const{value:C,repeatable:k,optional:N,regexp:O}=m;o.push({name:C,repeatable:k,optional:N});const I=O||ja;if(I!==ja){g+=ft.BonusCustomRegExp;try{`${I}`}catch(v){throw new Error(`Invalid custom RegExp for param "${C}" (${I}): `+v.message)}}let b=k?`((?:${I})(?:/(?:${I}))*)`:`(${I})`;d||(b=N&&u.length<2?`(?:/${b})`:"/"+b),N&&(b+="?"),l+=b,g+=ft.Dynamic,N&&(g+=ft.BonusOptional),k&&(g+=ft.BonusRepeatable),I===".*"&&(g+=ft.BonusWildcard)}f.push(g)}s.push(f)}if(n.strict&&n.end){const u=s.length-1;s[u][s[u].length-1]+=ft.BonusStrict}n.strict||(l+="/?"),n.end?l+="$":n.strict&&!l.endsWith("/")&&(l+="(?:/|$)");const r=new RegExp(l,n.sensitive?"":"i");function a(u){const f=u.match(r),d={};if(!f)return null;for(let m=1;m<f.length;m++){const g=f[m]||"",C=o[m-1];d[C.name]=g&&C.repeatable?g.split("/"):g}return d}function i(u){let f="",d=!1;for(const m of e){(!d||!f.endsWith("/"))&&(f+="/"),d=!1;for(const g of m)if(g.type===Pn.Static)f+=g.value;else if(g.type===Pn.Param){const{value:C,repeatable:k,optional:N}=g,O=C in u?u[C]:"";if(Nt(O)&&!k)throw new Error(`Provided param "${C}" is an array but it is not repeatable (* or + modifiers)`);const I=Nt(O)?O.join("/"):O;if(!I)if(N)m.length<2&&(f.endsWith("/")?f=f.slice(0,-1):d=!0);else throw new Error(`Missing required param "${C}"`);f+=I}}return f||"/"}return{re:r,score:s,keys:o,parse:a,stringify:i}}function rv(e,t){let n=0;for(;n<e.length&&n<t.length;){const s=t[n]-e[n];if(s)return s;n++}return e.length<t.length?e.length===1&&e[0]===ft.Static+ft.Segment?-1:1:e.length>t.length?t.length===1&&t[0]===ft.Static+ft.Segment?1:-1:0}function cu(e,t){let n=0;const s=e.score,l=t.score;for(;n<s.length&&n<l.length;){const o=rv(s[n],l[n]);if(o)return o;n++}if(Math.abs(l.length-s.length)===1){if(Ba(s))return 1;if(Ba(l))return-1}return l.length-s.length}function Ba(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const av={strict:!1,end:!0,sensitive:!1};function iv(e,t,n){const s=lv(nv(e.path),n),l=Ee(s,{record:e,parent:t,children:[],alias:[]});return t&&!l.record.aliasOf==!t.record.aliasOf&&t.children.push(l),l}function cv(e,t){const n=[],s=new Map;t=Ra(av,t);function l(d){return s.get(d)}function o(d,m,g){const C=!g,k=Ka(d);k.aliasOf=g&&g.record;const N=Ra(t,d),O=[k];if("alias"in d){const v=typeof d.alias=="string"?[d.alias]:d.alias;for(const T of v)O.push(Ka(Ee({},k,{components:g?g.record.components:k.components,path:T,aliasOf:g?g.record:k})))}let I,b;for(const v of O){const{path:T}=v;if(m&&T[0]!=="/"){const $=m.record.path,S=$[$.length-1]==="/"?"":"/";v.path=m.record.path+(T&&S+T)}if(I=iv(v,m,N),g?g.alias.push(I):(b=b||I,b!==I&&b.alias.push(I),C&&d.name&&!Ya(I)&&r(d.name)),uu(I)&&i(I),k.children){const $=k.children;for(let S=0;S<$.length;S++)o($[S],I,g&&g.children[S])}g=g||I}return b?()=>{r(b)}:bs}function r(d){if(ru(d)){const m=s.get(d);m&&(s.delete(d),n.splice(n.indexOf(m),1),m.children.forEach(r),m.alias.forEach(r))}else{const m=n.indexOf(d);m>-1&&(n.splice(m,1),d.record.name&&s.delete(d.record.name),d.children.forEach(r),d.alias.forEach(r))}}function a(){return n}function i(d){const m=dv(d,n);n.splice(m,0,d),d.record.name&&!Ya(d)&&s.set(d.record.name,d)}function u(d,m){let g,C={},k,N;if("name"in d&&d.name){if(g=s.get(d.name),!g)throw es(Ue.MATCHER_NOT_FOUND,{location:d});N=g.record.name,C=Ee(Ga(m.params,g.keys.filter(b=>!b.optional).concat(g.parent?g.parent.keys.filter(b=>b.optional):[]).map(b=>b.name)),d.params&&Ga(d.params,g.keys.map(b=>b.name))),k=g.stringify(C)}else if(d.path!=null)k=d.path,g=n.find(b=>b.re.test(k)),g&&(C=g.parse(k),N=g.record.name);else{if(g=m.name?s.get(m.name):n.find(b=>b.re.test(m.path)),!g)throw es(Ue.MATCHER_NOT_FOUND,{location:d,currentLocation:m});N=g.record.name,C=Ee({},m.params,d.params),k=g.stringify(C)}const O=[];let I=g;for(;I;)O.unshift(I.record),I=I.parent;return{name:N,path:k,params:C,matched:O,meta:fv(O)}}e.forEach(d=>o(d));function f(){n.length=0,s.clear()}return{addRoute:o,resolve:u,removeRoute:r,clearRoutes:f,getRoutes:a,getRecordMatcher:l}}function Ga(e,t){const n={};for(const s of t)s in e&&(n[s]=e[s]);return n}function Ka(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:uv(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 uv(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const s in e.components)t[s]=typeof n=="object"?n[s]:n;return t}function Ya(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function fv(e){return e.reduce((t,n)=>Ee(t,n.meta),{})}function dv(e,t){let n=0,s=t.length;for(;n!==s;){const o=n+s>>1;cu(e,t[o])<0?s=o:n=o+1}const l=mv(e);return l&&(s=t.lastIndexOf(l,s-1)),s}function mv(e){let t=e;for(;t=t.parent;)if(uu(t)&&cu(e,t)===0)return t}function uu({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function qa(e){const t=gt(Io),n=gt(ir),s=fe(()=>{const i=ke(e.to);return t.resolve(i)}),l=fe(()=>{const{matched:i}=s.value,{length:u}=i,f=i[u-1],d=n.matched;if(!f||!d.length)return-1;const m=d.findIndex(Zn.bind(null,f));if(m>-1)return m;const g=Xa(i[u-2]);return u>1&&Xa(f)===g&&d[d.length-1].path!==g?d.findIndex(Zn.bind(null,i[u-2])):m}),o=fe(()=>l.value>-1&&bv(n.params,s.value.params)),r=fe(()=>l.value>-1&&l.value===n.matched.length-1&&lu(n.params,s.value.params));function a(i={}){if(vv(i)){const u=t[ke(e.replace)?"replace":"push"](ke(e.to)).catch(bs);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>u),u}return Promise.resolve()}return{route:s,href:fe(()=>s.value.href),isActive:o,isExactActive:r,navigate:a}}function pv(e){return e.length===1?e[0]:e}const hv=Oe({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"},viewTransition:Boolean},useLink:qa,setup(e,{slots:t}){const n=Ds(qa(e)),{options:s}=gt(Io),l=fe(()=>({[za(e.activeClass,s.linkActiveClass,"router-link-active")]:n.isActive,[za(e.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const o=t.default&&pv(t.default(n));return e.custom?o:Us("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:l.value},o)}}}),gv=hv;function vv(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function bv(e,t){for(const n in t){const s=t[n],l=e[n];if(typeof s=="string"){if(s!==l)return!1}else if(!Nt(l)||l.length!==s.length||s.some((o,r)=>o!==l[r]))return!1}return!0}function Xa(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const za=(e,t,n)=>e??t??n,_v=Oe({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const s=gt(Ll),l=fe(()=>e.route||s.value),o=gt(Ha,0),r=fe(()=>{let u=ke(o);const{matched:f}=l.value;let d;for(;(d=f[u])&&!d.components;)u++;return u}),a=fe(()=>l.value.matched[r.value]);hs(Ha,fe(()=>r.value+1)),hs(Yg,a),hs(Ll,l);const i=q();return mt(()=>[i.value,a.value,e.name],([u,f,d],[m,g,C])=>{f&&(f.instances[d]=u,g&&g!==f&&u&&u===m&&(f.leaveGuards.size||(f.leaveGuards=g.leaveGuards),f.updateGuards.size||(f.updateGuards=g.updateGuards))),u&&f&&(!g||!Zn(f,g)||!m)&&(f.enterCallbacks[d]||[]).forEach(k=>k(u))},{flush:"post"}),()=>{const u=l.value,f=e.name,d=a.value,m=d&&d.components[f];if(!m)return Qa(n.default,{Component:m,route:u});const g=d.props[f],C=g?g===!0?u.params:typeof g=="function"?g(u):g:null,N=Us(m,Ee({},C,t,{onVnodeUnmounted:O=>{O.component.isUnmounted&&(d.instances[f]=null)},ref:i}));return Qa(n.default,{Component:N,route:u})||N}}});function Qa(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const yv=_v;function wv(e){const t=cv(e.routes,e),n=e.parseQuery||Gg,s=e.stringifyQuery||Va,l=e.history,o=is(),r=is(),a=is(),i=jl(on);let u=on;jn&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const f=Qo.bind(null,F=>""+F),d=Qo.bind(null,Lg),m=Qo.bind(null,Is);function g(F,ee){let Q,ne;return ru(F)?(Q=t.getRecordMatcher(F),ne=ee):ne=F,t.addRoute(ne,Q)}function C(F){const ee=t.getRecordMatcher(F);ee&&t.removeRoute(ee)}function k(){return t.getRoutes().map(F=>F.record)}function N(F){return!!t.getRecordMatcher(F)}function O(F,ee){if(ee=Ee({},ee||i.value),typeof F=="string"){const y=Jo(n,F,ee.path),R=t.resolve({path:y.path},ee),j=l.createHref(y.fullPath);return Ee(y,R,{params:m(R.params),hash:Is(y.hash),redirectedFrom:void 0,href:j})}let Q;if(F.path!=null)Q=Ee({},F,{path:Jo(n,F.path,ee.path).path});else{const y=Ee({},F.params);for(const R in y)y[R]==null&&delete y[R];Q=Ee({},F,{params:d(y)}),ee.params=d(ee.params)}const ne=t.resolve(Q,ee),me=F.hash||"";ne.params=f(m(ne.params));const _=Ig(s,Ee({},F,{hash:Cg(me),path:ne.path})),w=l.createHref(_);return Ee({fullPath:_,hash:me,query:s===Va?Kg(F.query):F.query||{}},ne,{redirectedFrom:void 0,href:w})}function I(F){return typeof F=="string"?Jo(n,F,i.value.path):Ee({},F)}function b(F,ee){if(u!==F)return es(Ue.NAVIGATION_CANCELLED,{from:ee,to:F})}function v(F){return S(F)}function T(F){return v(Ee(I(F),{replace:!0}))}function $(F,ee){const Q=F.matched[F.matched.length-1];if(Q&&Q.redirect){const{redirect:ne}=Q;let me=typeof ne=="function"?ne(F,ee):ne;return typeof me=="string"&&(me=me.includes("?")||me.includes("#")?me=I(me):{path:me},me.params={}),Ee({query:F.query,hash:F.hash,params:me.path!=null?{}:F.params},me)}}function S(F,ee){const Q=u=O(F),ne=i.value,me=F.state,_=F.force,w=F.replace===!0,y=$(Q,ne);if(y)return S(Ee(I(y),{state:typeof y=="object"?Ee({},me,y.state):me,force:_,replace:w}),ee||Q);const R=Q;R.redirectedFrom=ee;let j;return!_&&Pg(s,ne,Q)&&(j=es(Ue.NAVIGATION_DUPLICATED,{to:R,from:ne}),Ae(ne,ne,!0,!1)),(j?Promise.resolve(j):H(R,ne)).catch(W=>Gt(W)?Gt(W,Ue.NAVIGATION_GUARD_REDIRECT)?W:tt(W):pe(W,R,ne)).then(W=>{if(W){if(Gt(W,Ue.NAVIGATION_GUARD_REDIRECT))return S(Ee({replace:w},I(W.to),{state:typeof W.to=="object"?Ee({},me,W.to.state):me,force:_}),ee||R)}else W=P(R,ne,!0,w,me);return M(R,ne,W),W})}function L(F,ee){const Q=b(F,ee);return Q?Promise.reject(Q):Promise.resolve()}function x(F){const ee=B.values().next().value;return ee&&typeof ee.runWithContext=="function"?ee.runWithContext(F):F()}function H(F,ee){let Q;const[ne,me,_]=qg(F,ee);Q=el(ne.reverse(),"beforeRouteLeave",F,ee);for(const y of ne)y.leaveGuards.forEach(R=>{Q.push(cn(R,F,ee))});const w=L.bind(null,F,ee);return Q.push(w),ve(Q).then(()=>{Q=[];for(const y of o.list())Q.push(cn(y,F,ee));return Q.push(w),ve(Q)}).then(()=>{Q=el(me,"beforeRouteUpdate",F,ee);for(const y of me)y.updateGuards.forEach(R=>{Q.push(cn(R,F,ee))});return Q.push(w),ve(Q)}).then(()=>{Q=[];for(const y of _)if(y.beforeEnter)if(Nt(y.beforeEnter))for(const R of y.beforeEnter)Q.push(cn(R,F,ee));else Q.push(cn(y.beforeEnter,F,ee));return Q.push(w),ve(Q)}).then(()=>(F.matched.forEach(y=>y.enterCallbacks={}),Q=el(_,"beforeRouteEnter",F,ee,x),Q.push(w),ve(Q))).then(()=>{Q=[];for(const y of r.list())Q.push(cn(y,F,ee));return Q.push(w),ve(Q)}).catch(y=>Gt(y,Ue.NAVIGATION_CANCELLED)?y:Promise.reject(y))}function M(F,ee,Q){a.list().forEach(ne=>x(()=>ne(F,ee,Q)))}function P(F,ee,Q,ne,me){const _=b(F,ee);if(_)return _;const w=ee===on,y=jn?history.state:{};Q&&(ne||w?l.replace(F.fullPath,Ee({scroll:w&&y&&y.scroll},me)):l.push(F.fullPath,me)),i.value=F,Ae(F,ee,Q,w),tt()}let Y;function Se(){Y||(Y=l.listen((F,ee,Q)=>{if(!le.listening)return;const ne=O(F),me=$(ne,le.currentRoute.value);if(me){S(Ee(me,{replace:!0,force:!0}),ne).catch(bs);return}u=ne;const _=i.value;jn&&Vg(Ua(_.fullPath,Q.delta),No()),H(ne,_).catch(w=>Gt(w,Ue.NAVIGATION_ABORTED|Ue.NAVIGATION_CANCELLED)?w:Gt(w,Ue.NAVIGATION_GUARD_REDIRECT)?(S(Ee(I(w.to),{force:!0}),ne).then(y=>{Gt(y,Ue.NAVIGATION_ABORTED|Ue.NAVIGATION_DUPLICATED)&&!Q.delta&&Q.type===Sl.pop&&l.go(-1,!1)}).catch(bs),Promise.reject()):(Q.delta&&l.go(-Q.delta,!1),pe(w,ne,_))).then(w=>{w=w||P(ne,_,!1),w&&(Q.delta&&!Gt(w,Ue.NAVIGATION_CANCELLED)?l.go(-Q.delta,!1):Q.type===Sl.pop&&Gt(w,Ue.NAVIGATION_ABORTED|Ue.NAVIGATION_DUPLICATED)&&l.go(-1,!1)),M(ne,_,w)}).catch(bs)}))}let Re=is(),de=is(),ae;function pe(F,ee,Q){tt(F);const ne=de.list();return ne.length?ne.forEach(me=>me(F,ee,Q)):console.error(F),Promise.reject(F)}function Xe(){return ae&&i.value!==on?Promise.resolve():new Promise((F,ee)=>{Re.add([F,ee])})}function tt(F){return ae||(ae=!F,Se(),Re.list().forEach(([ee,Q])=>F?Q(F):ee()),Re.reset()),F}function Ae(F,ee,Q,ne){const{scrollBehavior:me}=e;if(!jn||!me)return Promise.resolve();const _=!Q&&Hg(Ua(F.fullPath,0))||(ne||!Q)&&history.state&&history.state.scroll||null;return Rs().then(()=>me(F,ee,_)).then(w=>w&&Ug(w)).catch(w=>pe(w,F,ee))}const De=F=>l.go(F);let pt;const B=new Set,le={currentRoute:i,listening:!0,addRoute:g,removeRoute:C,clearRoutes:t.clearRoutes,hasRoute:N,getRoutes:k,resolve:O,options:e,push:v,replace:T,go:De,back:()=>De(-1),forward:()=>De(1),beforeEach:o.add,beforeResolve:r.add,afterEach:a.add,onError:de.add,isReady:Xe,install(F){F.component("RouterLink",gv),F.component("RouterView",yv),F.config.globalProperties.$router=le,Object.defineProperty(F.config.globalProperties,"$route",{enumerable:!0,get:()=>ke(i)}),jn&&!pt&&i.value===on&&(pt=!0,v(l.location).catch(ne=>{}));const ee={};for(const ne in on)Object.defineProperty(ee,ne,{get:()=>i.value[ne],enumerable:!0});F.provide(Io,le),F.provide(ir,xi(ee)),F.provide(Ll,i);const Q=F.unmount;B.add(F),F.unmount=function(){B.delete(F),B.size<1&&(u=on,Y&&Y(),Y=null,i.value=on,pt=!1,ae=!1),Q()}}};function ve(F){return F.reduce((ee,Q)=>ee.then(()=>x(Q)),Promise.resolve())}return le}function xv(){return gt(Io)}function Ev(e){return gt(ir)}const kv="/logo.png",Cv={class:"language-switcher"},Sv=["value","title"],Tv=Oe({__name:"LanguageSwitcher",setup(e){const{locale:t}=je(),n=fe({get:()=>t.value,set:l=>{t.value=l,localStorage.setItem("language",l)}});function s(l){const o=l.target;n.value=o.value}return(l,o)=>(K(),Z("div",Cv,[c("select",{value:n.value,onChange:s,class:"px-3 py-2 border rounded-lg focus:ring-blue-500 focus:border-blue-500 bg-white",title:l.$t("common.language")},[...o[0]||(o[0]=[c("option",{value:"zh"},"中文",-1),c("option",{value:"en"},"English",-1)])],40,Sv)]))}}),Lv={class:"app-layout"},$v={class:"mb-8"},Nv={class:"flex items-center mb-4"},Iv=["alt"],Pv={class:"text-xl font-bold text-gray-800"},Av={class:"space-y-2"},Dv={class:"mt-4 pt-4 border-t"},Ov=Oe({__name:"Layout",emits:["new-download"],setup(e,{emit:t}){const n=xv(),s=Ev(),l=zl(),o=q(window.innerWidth<=768),r=q("download"),a=fe(()=>typeof window<"u"&&!!window.electron),i=t,u=gt("showGlobalNewDownload");function f(){o.value=!o.value}function d(k){if(console.log("[Layout] switchSection 被调用,section:",k,"当前路径:",s.path),k==="ariang"){m();return}const N=`/page/${k}`;if(console.log("[Layout] 准备导航到:",N),s.path===N){console.log("[Layout] 已在目标路径,跳过导航"),r.value=k;return}r.value=k,n.push(N).then(()=>{console.log("[Layout] 导航成功,当前路径:",s.path,"当前名称:",s.name),s.name&&(r.value=s.name)}).catch(O=>{O.name!=="NavigationDuplicated"?console.error("[Layout] 路由导航失败:",O):console.log("[Layout] 导航重复,已忽略")}),window.innerWidth<=768&&(o.value=!0)}function m(){const N=l.serverInfo.ariang?"./ariang/":"http://lzw.me/x/ariang/";window.open(N)}function g(){u?u():i("new-download")}function C(){window.innerWidth>768?o.value=!1:o.value=!0}return mt(()=>s.name,k=>{k&&(r.value=k)},{immediate:!0}),mt(()=>s.path,k=>{k.startsWith("/page/download")?r.value="download":k.startsWith("/page/web-browser")?r.value="web-browser":k.startsWith("/page/completed")?r.value="completed":k.startsWith("/page/config")?r.value="config":k.startsWith("/page/about")&&(r.value="about")},{immediate:!0}),Vt(()=>{window.addEventListener("resize",C),C()}),On(()=>{window.removeEventListener("resize",C)}),(k,N)=>(K(),Z("div",Lv,[c("button",{class:"menu-toggle",onClick:f},[c("i",{class:Qe(["fas",o.value?"fa-bars":"fa-times"])},null,2)]),c("div",{class:Qe(["sidebar p-4",{show:!o.value}])},[c("div",$v,[c("div",Nv,[c("img",{src:kv,alt:k.$t("layout.title"),class:"w-8 h-8 mr-2"},null,8,Iv),c("h1",Pv,E(k.$t("layout.title")),1)]),c("button",{onClick:g,class:"w-full bg-blue-500 hover:bg-blue-600 text-white p-2 rounded-lg flex items-center justify-center transition-colors"},[N[5]||(N[5]=c("i",{class:"fas fa-plus mr-2"},null,-1)),_e(E(k.$t("layout.newDownload")),1)])]),c("nav",Av,[c("button",{onClick:N[0]||(N[0]=O=>d("download")),class:Qe(["nav-item w-full p-3 rounded-lg flex items-center",{active:r.value==="download"}])},[N[6]||(N[6]=c("i",{class:"fas fa-download mr-3"},null,-1)),_e(E(k.$t("layout.downloadManagement")),1)],2),a.value?(K(),Z("button",{key:0,onClick:N[1]||(N[1]=O=>d("web-browser")),class:Qe(["nav-item w-full p-3 rounded-lg flex items-center",{active:r.value==="web-browser"}])},[N[7]||(N[7]=c("i",{class:"fas fa-globe mr-3"},null,-1)),_e(E(k.$t("layout.webBrowser")),1)],2)):se("",!0),c("button",{onClick:N[2]||(N[2]=O=>d("completed")),class:Qe(["nav-item w-full p-3 rounded-lg flex items-center",{active:r.value==="completed"}])},[N[8]||(N[8]=c("i",{class:"fas fa-check-circle mr-3"},null,-1)),_e(E(k.$t("layout.completed")),1)],2),c("button",{onClick:N[3]||(N[3]=O=>d("config")),class:Qe(["nav-item w-full p-3 rounded-lg flex items-center",{active:r.value==="config"}])},[N[9]||(N[9]=c("i",{class:"fas fa-cog mr-3"},null,-1)),_e(E(k.$t("layout.config")),1)],2),c("button",{onClick:N[4]||(N[4]=O=>d("about")),class:Qe(["nav-item w-full p-3 rounded-lg flex items-center",{active:r.value==="about"}])},[N[10]||(N[10]=c("i",{class:"fas fa-info-circle mr-3"},null,-1)),_e(E(k.$t("layout.about")),1)],2),c("button",{onClick:m,class:"nav-item w-full p-3 rounded-lg flex items-center"},[N[11]||(N[11]=c("i",{class:"fas fa-link mr-3"},null,-1)),_e(E(k.$t("layout.ariang")),1)])]),c("div",Dv,[ye(Tv)])],2),c("div",{class:Qe(["main-content",{"sidebar-collapsed":o.value}])},[Vi(k.$slots,"default",{},void 0,!0)],2)]))}}),Po=(e,t)=>{const n=e.__vccOpts||e;for(const[s,l]of t)n[s]=l;return n},Vs=Po(Ov,[["__scopeId","data-v-a75620cd"]]);function ts(e){return e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(2)} KB`:e<1024*1024*1024?`${(e/(1024*1024)).toFixed(2)} MB`:`${(e/(1024*1024*1024)).toFixed(2)} GB`}function Rv(e){return e<1024?`${e} B/s`:e<1024*1024?`${(e/1024).toFixed(2)} KB/s`:e<1024*1024*1024?`${(e/(1024*1024)).toFixed(2)} MB/s`:`${(e/(1024*1024*1024)).toFixed(2)} GB/s`}function uo(e){return e/=1e3,e<60?`${e}秒`:e<3600?`${(e/60).toFixed(2)}分钟`:e<3600*24?`${(e/3600).toFixed(2)}小时`:`${(e/(3600*24)).toFixed(2)}天`}const Mv={class:"p-1 md:p-2"},Fv={class:"bg-white rounded-lg shadow p-6"},Uv={class:"text-xl font-semibold mb-6 text-center"},Vv={class:"space-y-6"},Hv={class:"text-lg font-medium text-green-700 mb-2"},Wv={class:"bg-gray-50 p-4 rounded-lg"},jv={class:"text-gray-600 mb-2"},Bv={class:"text-gray-600 mb-2"},Gv={class:"text-gray-600 mb-2"},Kv={class:"text-gray-600"},Yv={class:"text-gray-600"},qv={href:"https://github.com/lzwme/m3u8-dl/release",target:"_blank",rel:"noopener",class:"text-blue-500 hover:text-blue-600"},Xv={class:"text-gray-600"},zv={key:1,class:"text-blue-600"},Qv={key:2,class:"text-green-600"},Jv={class:"text-lg font-medium text-green-700 mb-2"},Zv={class:"text-gray-600"},eb={class:"text-lg font-medium text-green-700 mb-2"},tb={class:"list-disc list-inside text-gray-600 space-y-2"},nb={class:"text-lg font-medium text-green-700 mb-2"},sb={class:"bg-gray-50 p-4 rounded-lg"},ob={class:"text-gray-600 mb-2"},lb={class:"text-gray-600 mt-4 mb-2"},rb={class:"text-lg font-medium text-green-700 mb-2"},ab={class:"bg-gray-50 p-4 rounded-lg"},ib={class:"text-gray-600 mb-2"},cb={class:"text-gray-600 mt-4 mb-2"},ub={class:"text-gray-600 mt-4"},fb=Oe({__name:"About",setup(e){const{t}=je(),n=zl(),s=fe(()=>n.serverInfo);async function l(){try{const r=await(await fetch("https://registry.npmmirror.com/@lzwme/m3u8-dl/latest")).json();r.version&&(r.version===s.value.version?be({text:t("about.latestVersion",{version:r.version}),type:"success"}):(n.updateServerInfo({newVersion:r.version}),window.electron?window.electron.ipc.send("checkForUpdate"):be({text:t("about.newVersionAvailable",{version:r.version,url:"https://github.com/lzwme/m3u8-dl/releases"}),type:"success",duration:1e4})))}catch(o){console.error("检查新版本失败:",o),be({text:t("about.versionCheckFailed",{error:o instanceof Error?o.message:t("error.unknownError")}),type:"error"})}}return Vt(()=>{window.electron&&window.electron.ipc.on("downloadProgress",r=>{console.log("downloadProgress",r),n.updateServerInfo({appUpdateMessage:`下载中:${Number(r.percent).toFixed(2)}% [${Rv(r.bytesPerSecond)}] [${ts(r.transferred)}/${ts(r.total)}]`})})}),(o,r)=>(K(),Ut(Vs,{onNewDownload:()=>{}},{default:Ft(()=>[c("div",Mv,[c("div",Fv,[c("h2",Uv,E(o.$t("about.title")),1),c("div",Vv,[c("div",null,[c("h3",Hv,E(o.$t("about.projectInfo")),1),c("div",Wv,[c("p",jv,[c("strong",null,E(o.$t("about.license"))+":",1),r[0]||(r[0]=_e("MIT",-1))]),c("p",Bv,[c("strong",null,E(o.$t("about.author"))+":",1),r[1]||(r[1]=c("a",{href:"https://lzw.me",target:"_blank",rel:"noopener",class:"text-blue-500 hover:text-blue-600"},"renxia",-1))]),c("p",Gv,[c("strong",null,E(o.$t("about.github"))+":",1),r[2]||(r[2]=c("a",{href:"https://github.com/lzwme/m3u8-dl.git",target:"_blank",rel:"noopener",class:"text-blue-500 hover:text-blue-600"},"https://github.com/lzwme/m3u8-dl.git",-1))]),c("p",Kv,[c("strong",null,E(o.$t("about.issues"))+":",1),r[3]||(r[3]=c("a",{href:"https://github.com/lzwme/m3u8-dl/issues",target:"_blank",rel:"noopener",class:"text-blue-500 hover:text-blue-600"}," https://github.com/lzwme/m3u8-dl/issues",-1))]),c("p",Yv,[c("strong",null,E(o.$t("about.currentVersion"))+":",1),c("a",qv,E(s.value.version),1)]),c("p",Xv,[c("strong",null,E(o.$t("about.checkVersion"))+":",1),s.value.appUpdateMessage?se("",!0):(K(),Z("button",{key:0,onClick:l,class:"px-2 py-1 text-sm bg-green-600 hover:bg-green-700 text-white rounded"},[r[4]||(r[4]=c("i",{class:"fas fa-check mr-1"},null,-1)),_e(E(o.$t("about.checkVersion")),1)])),s.value.newVersion?(K(),Z("span",zv,E(o.$t("about.newVersionFound",{version:s.value.newVersion})),1)):se("",!0),s.value.appUpdateMessage?(K(),Z("span",Qv,E(s.value.appUpdateMessage),1)):se("",!0)])])]),c("div",null,[c("h3",Jv,E(o.$t("about.projectDescription")),1),c("p",Zv,[r[5]||(r[5]=c("a",{href:"https://github.com/lzwme/m3u8-dl",target:"_blank",rel:"noopener",class:"text-blue-500 hover:text-blue-600"},"@lzwme/m3u8-dl",-1)),_e(" "+E(o.$t("about.projectDescriptionText")),1)])]),c("div",null,[c("h3",eb,E(o.$t("about.features")),1),c("ul",tb,[c("li",null,E(o.$t("about.feature1")),1),c("li",null,E(o.$t("about.feature2")),1),c("li",null,E(o.$t("about.feature3")),1),c("li",null,E(o.$t("about.feature4")),1),c("li",null,E(o.$t("about.feature5")),1),c("li",null,E(o.$t("about.feature6")),1),c("li",null,E(o.$t("about.feature7")),1),c("li",null,E(o.$t("about.feature8")),1)])]),c("div",null,[c("h3",nb,E(o.$t("about.installation")),1),c("div",sb,[c("p",ob,E(o.$t("about.globalInstall")),1),r[6]||(r[6]=c("pre",{class:"bg-gray-800 text-gray-100 p-3 rounded-lg overflow-x-auto"},[_e("npm i -g @lzwme/m3u8-dl"),c("br"),_e("m3u8dl -h")],-1)),c("p",lb,E(o.$t("about.useNpx")),1),r[7]||(r[7]=c("pre",{class:"bg-gray-800 text-gray-100 p-3 rounded-lg overflow-x-auto"},"npx @lzwme/m3u8-dl -h",-1))])]),c("div",null,[c("h3",rb,E(o.$t("about.docker")),1),c("div",ab,[c("p",ib,E(o.$t("about.dockerCommand")),1),r[8]||(r[8]=c("pre",{class:"bg-gray-800 text-gray-100 p-3 rounded-lg overflow-x-auto"},"docker run -d --name m3u8-dl -p 6600:6600 -v ./downloads:/app/downloads -v ./cache:/app/cache lzwme/m3u8-dl",-1)),c("p",cb,E(o.$t("about.dockerCompose")),1),r[9]||(r[9]=c("pre",{class:"bg-gray-800 text-gray-100 p-3 rounded-lg overflow-x-auto"},`version: '3'
|
|
15
|
+
services:
|
|
16
|
+
m3u8-dl:
|
|
17
|
+
image: lzwme/m3u8-dl
|
|
18
|
+
container_name: m3u8-dl
|
|
19
|
+
ports:
|
|
20
|
+
- "6600:6600"
|
|
21
|
+
volumes:
|
|
22
|
+
- ./downloads:/app/downloads
|
|
23
|
+
- ./cache:/app/cache
|
|
24
|
+
restart: unless-stopped`,-1)),c("p",ub,E(o.$t("about.dockerDeployComplete",{url:"http://localhost:6600"})),1)])])])])])]),_:1}))}}),db={class:"bg-white rounded-lg shadow"},mb={class:"p-4"},pb={class:"flex justify-between items-center"},hb={class:"text-xl font-semibold"},gb={class:"flex items-center space-x-2"},vb={class:"text-sm text-gray-600"},bb={class:"px-4 pb-2 border-b"},_b={class:"flex items-center space-x-4"},yb={class:"flex items-center space-x-2"},wb={class:"text-sm text-gray-600"},xb={value:"startTime"},Eb={value:"endTime"},kb={value:"name"},Cb={value:"size"},Sb={value:"saveDir"},Tb={class:"flex items-center space-x-2"},Lb=["title"],$b={class:"ml-1"},Nb={class:"flex items-center space-x-2"},Ib=["placeholder"],Pb={class:"overflow-x-auto"},Ab={class:"w-full"},Db={class:"bg-gray-50 border-b"},Ob={class:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider w-12"},Rb=["checked","indeterminate"],Mb={class:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider"},Fb={class:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider"},Ub={class:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider"},Vb={class:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider"},Hb={class:"px-4 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider"},Wb={class:"bg-white divide-y divide-gray-200"},jb={class:"px-4 py-3 whitespace-nowrap"},Bb=["checked","onChange"],Gb={class:"px-4 py-3 whitespace-nowrap text-sm"},Kb={class:"flex items-center space-x-2"},Yb=["onClick","title"],qb=["onClick","title"],Xb=["onClick","title"],zb={class:"px-4 py-3"},Qb={class:"flex items-center"},Jb={class:"flex-1 min-w-0"},Zb=["title"],e_=["title"],t_={class:"px-4 py-3 whitespace-nowrap text-sm text-gray-600"},n_={class:"px-4 py-3 whitespace-nowrap text-sm text-gray-600"},s_={class:"px-4 py-3 whitespace-nowrap text-sm text-gray-600"},o_={key:0},l_={colspan:"6",class:"px-4 py-8 text-center text-gray-500"},r_={class:"flex flex-col items-center"},a_={key:0,class:"px-4 py-3 bg-blue-50 border-t flex items-center justify-between"},i_={class:"text-sm text-gray-700"},c_={class:"flex items-center space-x-2"},u_=Oe({__name:"CompletedList",emits:["show-detail","local-play","delete"],setup(e,{emit:t}){const{t:n}=je(),s=Mn(),l=ss(),o=q("endTime"),r=q("desc"),a=q(""),i=fe(()=>{const H=Object.values(s.tasks).filter(M=>M.status==="done"||M.progress!==void 0&&M.progress>=100);return H.forEach(M=>{M.showName=M.filename||M.dlOptions?.filename||M.localVideo||M.url}),H}),u=fe(()=>{if(!a.value.trim())return i.value;const x=a.value.toLowerCase();return i.value.filter(H=>{const M=(H.showName||H.filename||H.url||"").toLowerCase(),P=(H.url||"").toLowerCase();return M.includes(x)||P.includes(x)})}),f=fe(()=>{const x=[...u.value];return x.sort((H,M)=>{let P,Y;switch(o.value){case"startTime":P=H.startTime||0,Y=M.startTime||0;break;case"endTime":P=H.endTime||0,Y=M.endTime||0;break;case"name":P=(H.showName||H.filename||H.url||"").toLowerCase(),Y=(M.showName||M.filename||M.url||"").toLowerCase();break;case"size":P=H.downloadedSize||H.size||0,Y=M.downloadedSize||M.size||0;break;case"saveDir":P=(H.dlOptions?.saveDir||H.options?.saveDir||"").toLowerCase(),Y=(M.dlOptions?.saveDir||M.options?.saveDir||"").toLowerCase();break;default:return 0}return P<Y?r.value==="asc"?-1:1:P>Y?r.value==="asc"?1:-1:0}),x}),d=q([]),m=fe(()=>f.value.length>0&&d.value.length===f.value.length),g=fe(()=>d.value.length>0&&d.value.length<f.value.length);function C(){}function k(){r.value=r.value==="asc"?"desc":"asc"}function N(){}function O(){m.value?d.value=[]:d.value=f.value.map(x=>x.url)}function I(x){const H=d.value.indexOf(x);H===-1?d.value.push(x):d.value.splice(H,1)}function b(x){if(!x)return"-";const H=new Date(x),{locale:M}=je(),P=M.value==="zh"?"zh-CN":"en-US";return H.toLocaleString(P,{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})}fe(()=>l.config);const v=t;function T(x){v("show-detail",x)}function $(x){const H=location.origin+`/localplay/${encodeURIComponent(x.localVideo||"")||x.localM3u8}`;v("local-play",{task:x,url:H})}function S(x){v("delete",[x])}function L(){d.value.length>0&&(v("delete",d.value),d.value=[])}return(x,H)=>(K(),Z("div",db,[c("div",mb,[c("div",pb,[c("h2",hb,E(x.$t("completedList.title")),1),c("div",gb,[c("span",vb,E(x.$t("completedList.total",{count:i.value.length})),1)])])]),c("div",bb,[c("div",_b,[c("div",yb,[c("label",wb,E(x.$t("completedList.sortBy")),1),Fe(c("select",{"onUpdate:modelValue":H[0]||(H[0]=M=>o.value=M),onChange:C,class:"px-3 py-1 text-sm border rounded-lg focus:ring-blue-500 focus:border-blue-500"},[c("option",xb,E(x.$t("completedList.sortStartTime")),1),c("option",Eb,E(x.$t("completedList.sortEndTime")),1),c("option",kb,E(x.$t("completedList.sortName")),1),c("option",Cb,E(x.$t("completedList.sortSize")),1),c("option",Sb,E(x.$t("completedList.sortSaveDir")),1)],544),[[Fd,o.value]])]),c("div",Tb,[c("button",{onClick:k,class:"px-3 py-1 text-sm bg-gray-100 hover:bg-gray-200 rounded-lg flex items-center",title:r.value==="asc"?x.$t("completedList.ascending"):x.$t("completedList.descending")},[c("i",{class:Qe(["fas",r.value==="asc"?"fa-sort-up":"fa-sort-down"])},null,2),c("span",$b,E(r.value==="asc"?x.$t("completedList.ascending"):x.$t("completedList.descending")),1)],8,Lb)]),H[3]||(H[3]=c("div",{class:"flex-1"},null,-1)),c("div",Nb,[Fe(c("input",{type:"text","onUpdate:modelValue":H[1]||(H[1]=M=>a.value=M),class:"px-3 py-1 text-sm border rounded-lg focus:ring-blue-500 focus:border-blue-500",placeholder:x.$t("completedList.searchPlaceholder"),onInput:N},null,40,Ib),[[ot,a.value]]),H[2]||(H[2]=c("i",{class:"fas fa-search text-gray-400"},null,-1))])])]),c("div",Pb,[c("table",Ab,[c("thead",Db,[c("tr",null,[c("th",Ob,[c("input",{type:"checkbox",checked:m.value,indeterminate:g.value,onChange:O,class:"form-checkbox h-4 w-4 text-blue-500 rounded focus:ring-blue-500"},null,40,Rb)]),c("th",Mb,E(x.$t("completedList.action")),1),c("th",Fb,E(x.$t("completedList.taskName")),1),c("th",Ub,E(x.$t("completedList.fileSize")),1),c("th",Vb,E(x.$t("completedList.startTime")),1),c("th",Hb,E(x.$t("completedList.endTime")),1)])]),c("tbody",Wb,[(K(!0),Z(Ge,null,xo(f.value,M=>(K(),Z("tr",{key:M.url,class:"hover:bg-gray-50 transition-colors"},[c("td",jb,[c("input",{type:"checkbox",checked:d.value.includes(M.url),onChange:P=>I(M.url),class:"form-checkbox h-4 w-4 text-blue-500 rounded focus:ring-blue-500"},null,40,Bb)]),c("td",Gb,[c("div",Kb,[c("button",{onClick:P=>T(M),class:"text-blue-600 hover:text-blue-800",title:x.$t("completedList.viewDetail")},[...H[4]||(H[4]=[c("i",{class:"fas fa-info-circle"},null,-1)])],8,Yb),M.localVideo?(K(),Z("button",{key:0,onClick:P=>$(M),class:"text-green-600 hover:text-green-800",title:x.$t("completedList.play")},[...H[5]||(H[5]=[c("i",{class:"fas fa-play-circle"},null,-1)])],8,qb)):se("",!0),c("button",{onClick:P=>S(M.url),class:"text-red-600 hover:text-red-800",title:x.$t("completedList.delete")},[...H[6]||(H[6]=[c("i",{class:"fas fa-trash"},null,-1)])],8,Xb)])]),c("td",zb,[c("div",Qb,[c("div",Jb,[c("p",{class:"text-sm font-medium text-gray-900 truncate",title:M.showName},E(M.showName),9,Zb),c("p",{class:"text-xs text-gray-500 truncate",title:M.url},E(M.url),9,e_)])])]),c("td",t_,E(ke(ts)(M.downloadedSize||M.size||0)),1),c("td",n_,E(b(M.startTime)),1),c("td",s_,E(b(M.endTime)),1)]))),128)),f.value.length===0?(K(),Z("tr",o_,[c("td",l_,[c("div",r_,[H[7]||(H[7]=c("i",{class:"fas fa-inbox text-4xl mb-2 text-gray-300"},null,-1)),c("p",null,E(x.$t("completedList.noCompletedTasks")),1)])])])):se("",!0)])])]),d.value.length>0?(K(),Z("div",a_,[c("span",i_,E(x.$t("completedList.selected",{count:d.value.length})),1),c("div",c_,[c("button",{onClick:L,class:"px-3 py-1 text-sm bg-red-500 hover:bg-red-600 text-white rounded"},[H[8]||(H[8]=c("i",{class:"fas fa-trash mr-1"},null,-1)),_e(E(x.$t("completedList.deleteSelected")),1)])])])):se("",!0)]))}}),f_={class:"bg-white rounded-lg shadow-xl max-w-3xl w-full max-h-[90vh] overflow-hidden flex flex-col"},d_={class:"flex justify-between items-center p-2 md:p-4 border-b"},m_={class:"text-lg md:text-xl font-semibold"},p_={class:"overflow-y-auto p-2 md:p-4 flex-1"},h_={key:0,class:"flex flex-col w-full text-left space-y-2 md:space-y-3"},g_={class:"flex items-start"},v_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},b_={class:"ml-1 md:ml-2 text-gray-800 break-words flex-1 text-sm md:text-base"},__={class:"flex items-center"},y_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},w_={class:"flex items-center"},x_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},E_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},k_={class:"flex items-center"},C_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},S_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},T_={class:"flex items-center"},L_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},$_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},N_={key:0},I_={key:0,class:"flex items-center"},P_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},A_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},D_={class:"text-green-600"},O_={class:"text-red-500"},R_={key:1,class:"flex items-center"},M_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},F_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},U_={key:2,class:"flex items-center"},V_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},H_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},W_={key:3,class:"flex items-center"},j_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},B_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},G_={key:4,class:"flex items-center"},K_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},Y_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},q_={key:5,class:"flex items-center"},X_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},z_={class:"ml-1 md:ml-2 text-gray-800 text-sm md:text-base"},Q_={class:"flex items-start"},J_={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},Z_={class:"ml-1 md:ml-2 flex-1 flex items-center gap-1 md:gap-2"},e0={class:"flex-1 p-1.5 md:p-2 bg-gray-50 rounded border text-xs md:text-sm text-gray-700 break-all"},t0=["title"],n0={key:6,class:"flex items-start"},s0={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},o0={class:"ml-1 md:ml-2 flex-1 flex items-center gap-1 md:gap-2"},l0={class:"flex-1 p-1.5 md:p-2 bg-gray-50 rounded border text-xs md:text-sm text-gray-700 break-all"},r0=["title"],a0={key:7,class:"flex items-start"},i0={class:"font-bold text-right inline-block text-sm md:text-base",style:{"min-width":"80px","max-width":"80px"}},c0={class:"ml-1 md:ml-2 text-red-600 break-words flex-1 text-sm md:text-base"},u0={class:"flex justify-end gap-2 p-2 md:p-4 border-t"},fu=Oe({__name:"TaskDetailModal",props:{visible:{type:Boolean},task:{}},emits:["close"],setup(e,{emit:t}){const{t:n}=je(),s=t;function l(){s("close")}function o(i){return{resume:n("download.status.resume"),pending:n("download.status.pending"),pause:n("download.status.pause"),error:n("download.status.error"),done:n("download.status.done")}[i]||i}function r(i){return{resume:"px-2 py-1 bg-green-100 text-green-800 rounded text-sm inline-block",pending:"px-2 py-1 bg-yellow-100 text-yellow-800 rounded text-sm inline-block",pause:"px-2 py-1 bg-gray-100 text-gray-800 rounded text-sm inline-block",error:"px-2 py-1 bg-red-100 text-red-600 rounded text-sm inline-block",done:"px-2 py-1 bg-blue-100 text-blue-800 rounded text-sm inline-block"}[i]||"px-2 py-1 bg-gray-100 text-gray-800 rounded text-sm inline-block"}async function a(i){try{await navigator.clipboard.writeText(i),be({text:n("toast.copySuccess"),type:"success"})}catch(u){console.error("复制失败:",u),be({text:n("toast.copyFailed"),type:"error"})}}return(i,u)=>e.visible?(K(),Z("div",{key:0,class:"fixed inset-0 modal-overlay flex items-center justify-center z-50 p-2 md:p-4",onClick:gn(l,["self"])},[c("div",f_,[c("div",d_,[c("h2",m_,E(i.$t("taskDetail.title")),1),c("button",{onClick:l,class:"text-gray-500 hover:text-gray-700 transition-colors p-1.5 md:p-2 rounded-lg hover:bg-gray-100"},[...u[2]||(u[2]=[c("i",{class:"fas fa-times"},null,-1)])])]),c("div",p_,[e.task?(K(),Z("div",h_,[c("div",g_,[c("label",v_,E(i.$t("taskDetail.name"))+":",1),c("span",b_,E(e.task.filename||e.task.localVideo||"-"),1)]),c("div",__,[c("label",y_,E(i.$t("taskDetail.status"))+":",1),c("span",{class:Qe([r(e.task.status),"ml-1 md:ml-2 text-xs md:text-sm"])},E(o(e.task.status)),3)]),c("div",w_,[c("label",x_,E(i.$t("taskDetail.progress"))+":",1),c("span",E_,E(e.task.progress||0)+"%",1)]),c("div",k_,[c("label",C_,E(i.$t("taskDetail.avgSpeed"))+":",1),c("span",S_,E(e.task.avgSpeedDesc||"-")+"/s",1)]),c("div",T_,[c("label",L_,E(i.$t("taskDetail.size"))+":",1),c("span",$_,[_e(E(ke(ts)(e.task.downloadedSize||0))+" ",1),e.task.size?(K(),Z("span",N_," / "+E(ke(ts)(e.task.size)),1)):se("",!0)])]),e.task.tsCount?(K(),Z("div",I_,[c("label",P_,E(i.$t("taskDetail.segments"))+":",1),c("span",A_,[c("span",D_,E(e.task.tsSuccess||0),1),u[3]||(u[3]=_e(" / ",-1)),c("span",O_,E(e.task.tsFailed||0),1),_e(" / "+E(e.task.tsCount),1)])])):se("",!0),e.task.threadNum?(K(),Z("div",R_,[c("label",M_,E(i.$t("taskDetail.threadNum"))+":",1),c("span",F_,E(e.task.threadNum),1)])):se("",!0),e.task.duration?(K(),Z("div",U_,[c("label",V_,E(i.$t("taskDetail.duration"))+":",1),c("span",H_,E(ke(uo)(e.task.duration*1e3)),1)])):se("",!0),e.task.startTime?(K(),Z("div",W_,[c("label",j_,E(i.$t("taskDetail.startTime"))+":",1),c("span",B_,E(new Date(e.task.startTime).toLocaleString()),1)])):se("",!0),e.task.endTime&&e.task.status!=="resume"?(K(),Z("div",G_,[c("label",K_,E(i.$t("taskDetail.endTime"))+":",1),c("span",Y_,E(new Date(e.task.endTime).toLocaleString()),1)])):se("",!0),e.task.status==="resume"&&e.task.remainingTime?(K(),Z("div",q_,[c("label",X_,E(i.$t("taskDetail.remainingTime"))+":",1),c("span",z_,E(ke(uo)(e.task.remainingTime)),1)])):se("",!0),c("div",Q_,[c("label",J_,E(i.$t("taskDetail.downloadUrl"))+":",1),c("div",Z_,[c("div",e0,E(e.task.url),1),c("button",{onClick:u[0]||(u[0]=f=>a(e.task.url)),class:"px-2 py-1.5 md:px-3 md:py-2 bg-blue-500 hover:bg-blue-600 text-white rounded transition-colors flex-shrink-0 text-sm",title:i.$t("taskDetail.copy")},[...u[4]||(u[4]=[c("i",{class:"fas fa-copy"},null,-1)])],8,t0)])]),e.task.localVideo||e.task.options?.saveDir?(K(),Z("div",n0,[c("label",s0,E(i.$t("taskDetail.saveLocation"))+":",1),c("div",o0,[c("div",l0,E(e.task.localVideo||e.task.options?.saveDir||"-"),1),e.task.localVideo||e.task.options?.saveDir?(K(),Z("button",{key:0,onClick:u[1]||(u[1]=f=>a(e.task.localVideo||e.task.options?.saveDir||"")),class:"px-2 py-1.5 md:px-3 md:py-2 bg-blue-500 hover:bg-blue-600 text-white rounded transition-colors flex-shrink-0 text-sm",title:i.$t("taskDetail.copy")},[...u[5]||(u[5]=[c("i",{class:"fas fa-copy"},null,-1)])],8,r0)):se("",!0)])])):se("",!0),e.task.errmsg?(K(),Z("div",a0,[c("label",i0,E(i.$t("taskDetail.relatedInfo"))+":",1),c("span",c0,E(e.task.errmsg),1)])):se("",!0)])):se("",!0)]),c("div",u0,[c("button",{onClick:l,class:"px-3 py-1.5 md:px-4 md:py-2 text-gray-600 hover:bg-gray-100 rounded-lg transition-colors text-sm md:text-base"},E(i.$t("taskDetail.close")),1)])])])):se("",!0)}}),f0={class:"bg-white rounded-lg shadow-xl max-w-md w-full"},d0={class:"p-6"},m0={class:"text-xl font-semibold mb-4"},p0={class:"text-gray-600 mb-6"},h0={class:"space-y-3 mb-6"},g0={class:"flex items-center cursor-pointer"},v0={class:"text-gray-700"},b0={class:"flex items-center cursor-pointer"},_0={class:"text-red-700 font-medium"},y0={class:"flex justify-end gap-3"},du=Oe({__name:"DeleteConfirmDialog",props:{visible:{type:Boolean},count:{}},emits:["close","confirm"],setup(e,{emit:t}){const{t:n}=je(),s=e,l=t,o=q(!0),r=q(!0);mt(()=>s.visible,u=>{u&&(o.value=!0,r.value=!0)});function a(){l("close")}function i(){l("confirm",{deleteCache:o.value,deleteVideo:r.value}),a()}return(u,f)=>e.visible?(K(),Z("div",{key:0,class:"fixed inset-0 modal-overlay flex items-center justify-center z-50 p-4",onClick:gn(a,["self"])},[c("div",f0,[c("div",d0,[c("h2",m0,E(u.$t("deleteConfirm.title")),1),c("p",p0,E(u.$t("deleteConfirm.message",{count:e.count})),1),c("div",h0,[c("label",g0,[Fe(c("input",{"onUpdate:modelValue":f[0]||(f[0]=d=>o.value=d),type:"checkbox",class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500 mr-3"},null,512),[[Bn,o.value]]),c("span",v0,E(u.$t("deleteConfirm.deleteCache")),1)]),c("label",b0,[Fe(c("input",{"onUpdate:modelValue":f[1]||(f[1]=d=>r.value=d),type:"checkbox",class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500 mr-3"},null,512),[[Bn,r.value]]),c("span",_0,E(u.$t("deleteConfirm.deleteVideo")),1)])]),c("div",y0,[c("button",{onClick:a,class:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded-lg transition-colors"},E(u.$t("deleteConfirm.cancel")),1),c("button",{onClick:i,class:"px-4 py-2 bg-red-500 hover:bg-red-600 text-white rounded-lg transition-colors"},E(u.$t("deleteConfirm.confirm")),1)])])])])):se("",!0)}}),w0={class:"bg-white rounded-lg shadow-xl max-w-md w-full"},x0={class:"p-6"},E0={class:"flex items-center mb-4"},k0={class:"text-xl font-semibold text-gray-900"},C0={class:"mb-6"},S0={class:"text-gray-600 whitespace-pre-line"},T0={class:"flex justify-end gap-3"},mu=Oe({__name:"ConfirmDialog",props:{visible:{type:Boolean},title:{},message:{}},emits:["close","confirm"],setup(e,{emit:t}){const{t:n}=je(),s=t;function l(){s("close")}function o(){s("confirm"),l()}return(r,a)=>e.visible?(K(),Z("div",{key:0,class:"fixed inset-0 modal-overlay flex items-center justify-center z-50 p-4",onClick:gn(l,["self"])},[c("div",w0,[c("div",x0,[c("div",E0,[a[0]||(a[0]=c("div",{class:"flex-shrink-0 w-10 h-10 bg-yellow-100 rounded-full flex items-center justify-center mr-3"},[c("i",{class:"fas fa-exclamation-triangle text-yellow-600"})],-1)),c("div",null,[c("h2",k0,E(e.title),1)])]),c("div",C0,[Vi(r.$slots,"default",{},()=>[c("p",S0,E(e.message),1)])]),c("div",T0,[c("button",{onClick:l,class:"px-4 py-2 text-gray-600 hover:bg-gray-100 rounded-lg transition-colors"},E(r.$t("common.cancel")),1),c("button",{onClick:o,class:"px-4 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-lg transition-colors"},E(r.$t("common.confirm")),1)])])])])):se("",!0)}}),L0={class:"flex items-center justify-between bg-gray-900 text-white px-4 py-2 flex-shrink-0"},$0={class:"flex items-center gap-4 flex-1 min-w-0"},N0=["title"],I0={class:"text-sm md:text-base font-semibold truncate flex-1"},P0={class:"flex items-center gap-2"},A0=["title"],D0={class:"flex-1 flex overflow-hidden relative"},O0={class:"flex-1 relative"},R0=["src"],M0={key:0,class:"playlist-sidebar w-80 bg-gray-900 text-white overflow-y-auto flex-shrink-0 border-l border-gray-700"},F0={class:"p-4"},U0={class:"flex items-center justify-between mb-3"},V0={class:"text-sm font-semibold text-gray-300"},H0=["title"],W0={class:"space-y-2"},j0=["onClick"],B0={class:"flex items-start justify-between gap-2"},G0={class:"flex-1 min-w-0"},K0={class:"font-medium text-sm truncate mb-1"},Y0={class:"text-xs text-gray-400 flex items-center gap-2 flex-wrap"},q0={key:0,class:"fas fa-play text-blue-300 flex-shrink-0 mt-1"},X0=Oe({__name:"VideoPlayer",props:{visible:{type:Boolean},initialUrl:{},initialTask:{}},emits:["close"],setup(e,{emit:t}){const{t:n}=je(),s=Mn(),l=e,o=t,r=q(null),a=q(!0),i=q(null),u=q(""),f=fe(()=>u.value?`./play.html?url=${encodeURIComponent(u.value)}`:""),d=fe(()=>{if(!i.value)return[];const I=i.value.dlOptions?.saveDir||i.value.options?.saveDir;if(!I)return[i.value];const v=Object.values(s.tasks).filter($=>!$.localVideo&&!$.localM3u8||($.progress||0)<20?!1:($.dlOptions?.saveDir||$.options?.saveDir)===I);return!v.some($=>$.url===i.value?.url)&&i.value&&v.push(i.value),v.sort(($,S)=>{const L=($.filename||$.showName||"").toLowerCase(),x=(S.filename||S.showName||"").toLowerCase();return L.localeCompare(x)})});mt(()=>[l.visible,l.initialUrl,l.initialTask],([I,b,v])=>{if(I&&(u.value=b,i.value=v||null,!i.value&&b)){const T=Object.values(s.tasks);i.value=T.find($=>{const S=$.localVideo||$.localM3u8;return S?`${location.origin}/localplay/${S}`===b:!1})||null}},{immediate:!0});function m(I){if(I.url===i.value?.url)return;const b=I.localVideo||I.localM3u8;if(!b){console.error("[VideoPlayer] switchVideo: task 缺少本地文件路径",I);return}const v=`${location.origin}/localplay/${b}`;u.value=v,i.value=I,r.value?.contentWindow&&r.value.contentWindow.postMessage({url:v,playType:v.includes("dplayer")?"dplayer":"artplayer"},"*")}function g(I){const b=I.data;if(!(!b||typeof b!="object")&&(b.action==="next"||b.action==="previous")){const v=d.value.findIndex(T=>T.url===i.value?.url);if(v===-1)return;if(b.action==="next"){const T=v+1;T<d.value.length&&m(d.value[T])}else if(b.action==="previous"){const T=v-1;T>=0&&m(d.value[T])}}}function C(){a.value=!a.value}function k(){o("close")}function N(I){return{resume:n("download.status.resume"),pending:n("download.status.pending"),pause:n("download.status.pause"),error:n("download.status.error"),done:n("download.status.done")}[I]||I}function O(I){return{resume:"bg-green-500/20 text-green-300",pending:"bg-yellow-500/20 text-yellow-300",pause:"bg-gray-500/20 text-gray-300",error:"bg-red-500/20 text-red-300",done:"bg-blue-500/20 text-blue-300"}[I]||"bg-gray-500/20 text-gray-300"}return Vt(()=>{window.addEventListener("message",g)}),On(()=>{window.removeEventListener("message",g)}),(I,b)=>e.visible?(K(),Z("div",{key:0,class:"fixed inset-0 bg-black z-100 flex flex-col",onKeydown:ql(k,["esc"]),tabindex:"0"},[c("div",L0,[c("div",$0,[c("button",{onClick:k,class:"text-gray-300 hover:text-white transition-colors p-2 rounded-lg hover:bg-gray-800",title:I.$t("common.close")},[...b[0]||(b[0]=[c("i",{class:"fas fa-times"},null,-1)])],8,N0),c("h2",I0,E(i.value?.filename||i.value?.showName||"视频播放"),1)]),c("div",P0,[d.value.length>1?(K(),Z("button",{key:0,onClick:C,class:"text-gray-300 hover:text-white transition-colors p-2 rounded-lg hover:bg-gray-800",title:a.value?"隐藏列表":"显示列表"},[c("i",{class:Qe(["fas",a.value?"fa-list-ul":"fa-list"])},null,2)],8,A0)):se("",!0)])]),c("div",D0,[c("div",O0,[c("iframe",{ref_key:"playerIframe",ref:r,src:f.value,class:"w-full h-full border-0",allowfullscreen:""},null,8,R0)]),ye(Ir,{name:"fade"},{default:Ft(()=>[a.value&&d.value.length>1?(K(),Z("div",{key:0,class:"playlist-overlay md:hidden fixed inset-0 bg-black/50 backdrop-blur-sm z-40",onClick:C})):se("",!0)]),_:1}),ye(Ir,{name:"slide"},{default:Ft(()=>[a.value&&d.value.length>1?(K(),Z("div",M0,[c("div",F0,[c("div",U0,[c("h3",V0,"播放列表 ("+E(d.value.length)+")",1),c("button",{onClick:C,class:"md:hidden text-gray-300 hover:text-white transition-colors p-2 rounded-lg hover:bg-gray-800",title:I.$t("common.close")},[...b[1]||(b[1]=[c("i",{class:"fas fa-times"},null,-1)])],8,H0)]),c("div",W0,[(K(!0),Z(Ge,null,xo(d.value,v=>(K(),Z("div",{key:v.url,onClick:T=>m(v),class:Qe(["p-3 rounded-lg cursor-pointer transition-colors",i.value?.url===v.url?"bg-blue-600 text-white":"bg-gray-800 hover:bg-gray-700 text-gray-200"])},[c("div",B0,[c("div",G0,[c("div",K0,E(v.filename||v.showName||v.url),1),c("div",Y0,[c("span",null,"进度: "+E(v.progress||0)+"%",1),v.status?(K(),Z("span",{key:0,class:Qe(["px-1.5 py-0.5 rounded text-xs",O(v.status)])},E(N(v.status)),3)):se("",!0)])]),i.value?.url===v.url?(K(),Z("i",q0)):se("",!0)])],10,j0))),128))])])])):se("",!0)]),_:1})])],32)):se("",!0)}}),pu=Po(X0,[["__scopeId","data-v-7740f374"]]),z0={class:"p-1 md:p-2"},Q0={key:0,class:"text-red-600 font-medium mb-2 whitespace-pre-line"},J0={class:"text-gray-600 whitespace-pre-line"},Z0=Oe({__name:"Completed",setup(e){const{t}=je(),n=Mn(),s=q(!1),l=q(!1),o=q(!1),r=q(!1),a=q(null),i=q([]),u=q(null),f=q(""),d=q(""),m=q(""),g=q(null);function C(v){a.value=v,s.value=!0}function k(v){v.length&&(i.value=v,l.value=!0)}async function N(v){const T=await bc(i.value,v.deleteCache,v.deleteVideo);T.code||(be({text:T.message||t("toast.deleteSuccess"),type:"success"}),n.deleteTasks(i.value)),i.value=[]}function O(v){const{task:T,url:$}=v;if(T.status==="error"){d.value=T.errmsg?t("confirm.playError",{error:T.errmsg}):"",f.value=t("confirm.playConfirmMessage"),u.value={task:T,url:$},o.value=!0;return}b($,T)}function I(){u.value&&(b(u.value.url,u.value.task),u.value=null)}function b(v,T){m.value=v,g.value=T||null,r.value=!0}return(v,T)=>(K(),Ut(Vs,null,{default:Ft(()=>[c("div",z0,[ye(u_,{onShowDetail:C,onLocalPlay:O,onDelete:k}),ye(fu,{visible:s.value,task:a.value,onClose:T[0]||(T[0]=$=>s.value=!1)},null,8,["visible","task"]),ye(du,{visible:l.value,count:i.value.length,onClose:T[1]||(T[1]=$=>l.value=!1),onConfirm:N},null,8,["visible","count"]),ye(mu,{visible:o.value,title:v.$t("confirm.play"),onClose:T[2]||(T[2]=$=>o.value=!1),onConfirm:I},{default:Ft(()=>[d.value?(K(),Z("p",Q0,E(d.value),1)):se("",!0),c("p",J0,E(f.value),1)]),_:1},8,["visible","title"]),ye(pu,{visible:r.value,"initial-url":m.value,"initial-task":g.value,onClose:T[3]||(T[3]=$=>r.value=!1)},null,8,["visible","initial-url","initial-task"])])]),_:1}))}}),ey={class:"p-1 md:p-2"},ty={class:"space-y-6"},ny={class:"bg-white rounded-lg shadow p-6 mb-6"},sy={class:"text-xl font-semibold mb-6"},oy={class:"grid grid-cols-1 md:grid-cols-2 gap-6"},ly={class:"block text-sm font-bold text-gray-700 mb-1"},ry=["placeholder"],ay={class:"mt-1 text-sm text-gray-500"},iy={class:"block text-sm font-bold text-gray-700 mb-1"},cy=["placeholder"],uy={class:"mt-1 text-sm text-gray-500"},fy={class:"block text-sm font-bold text-gray-700 mb-1"},dy={class:"flex"},my=["placeholder"],py={class:"mt-1 text-sm text-gray-500"},hy={class:"block text-sm font-bold text-gray-700 mb-1"},gy=["placeholder"],vy={class:"mt-1 text-sm text-gray-500"},by={class:"block text-sm font-bold text-gray-700 mb-1"},_y={class:"flex items-center mt-2"},yy={class:"inline-flex items-center"},wy={class:"ml-2 text-gray-700"},xy={class:"mt-1 text-sm text-gray-500"},Ey={class:"block text-sm font-bold text-gray-700 mb-1"},ky={class:"flex items-center mt-2"},Cy={class:"inline-flex items-center"},Sy={class:"ml-2 text-gray-700"},Ty={class:"block text-sm font-bold text-gray-700 mb-1"},Ly={class:"flex items-center mt-2"},$y={class:"inline-flex items-center"},Ny={class:"ml-2 text-gray-700"},Iy={class:"block text-sm font-bold text-gray-700 mb-1"},Py={class:"flex items-center mt-2"},Ay={class:"inline-flex items-center"},Dy={class:"ml-2 text-gray-700"},Oy={class:"flex justify-end space-x-4"},Ry={type:"submit",class:"px-6 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-lg"},My={class:"bg-white rounded-lg shadow p-6"},Fy={class:"text-xl font-semibold mb-6"},Uy={class:"grid grid-cols-1 md:grid-cols-2 gap-6"},Vy={class:"block text-sm font-bold text-gray-700 mb-1"},Hy={class:"flex"},Wy=["placeholder"],jy={class:"mt-1 text-sm text-gray-500"},By={class:"flex justify-end space-x-4"},Gy={type:"submit",class:"px-6 py-2 bg-blue-500 hover:bg-blue-600 text-white rounded-lg"},Ky=Oe({__name:"Config",setup(e){const{t}=je(),n=ss(),s=q(n.token||""),{connect:l}=Jl("");Vt(async()=>{await n.loadConfig(),s.value=n.token||localStorage.getItem("token")||""});async function o(){const a=await n.updateConfig();be({text:a.message||t("config.configUpdated"),type:a.code?"error":"success"})}async function r(){if(!(s.value!==n.token))return;let i=s.value;i&&(typeof window<"u"&&window.md5?i=window.md5(i).slice(0,8):i=btoa(i).replace(/[^a-zA-Z0-9]/g,"").slice(0,8)),n.token=i,i?(localStorage.setItem("token",i),await n.loadConfig()&&l()):localStorage.removeItem("token"),be({text:t("config.localConfigUpdated"),type:"success"})}return(a,i)=>(K(),Ut(Vs,{onNewDownload:()=>{}},{default:Ft(()=>[c("div",ey,[c("div",ty,[c("div",ny,[c("h2",sy,E(a.$t("config.downloadSettings")),1),c("form",{onSubmit:gn(o,["prevent"]),class:"space-y-6"},[c("div",oy,[c("div",null,[c("label",ly,E(a.$t("config.threadNum")),1),Fe(c("input",{"onUpdate:modelValue":i[0]||(i[0]=u=>ke(n).config.threadNum=u),type:"number",min:"0",max:"16",class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:a.$t("config.threadNumPlaceholder")},null,8,ry),[[ot,ke(n).config.threadNum,void 0,{number:!0}]]),c("p",ay,E(a.$t("config.threadNumHint")),1)]),c("div",null,[c("label",iy,E(a.$t("config.maxDownloads")),1),Fe(c("input",{"onUpdate:modelValue":i[1]||(i[1]=u=>ke(n).config.maxDownloads=u),type:"number",min:"1",max:"10",class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:a.$t("config.maxDownloadsPlaceholder")},null,8,cy),[[ot,ke(n).config.maxDownloads,void 0,{number:!0}]]),c("p",uy,E(a.$t("config.maxDownloadsHint")),1)]),c("div",null,[c("label",fy,E(a.$t("config.saveDir")),1),c("div",dy,[Fe(c("input",{"onUpdate:modelValue":i[2]||(i[2]=u=>ke(n).config.saveDir=u),type:"text",class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:a.$t("config.saveDirPlaceholder")},null,8,my),[[ot,ke(n).config.saveDir]])]),c("p",py,E(a.$t("config.saveDirHint")),1)]),c("div",null,[c("label",hy,E(a.$t("config.ffmpegPath")),1),Fe(c("input",{"onUpdate:modelValue":i[3]||(i[3]=u=>ke(n).config.ffmpegPath=u),type:"text",class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:a.$t("config.ffmpegPathPlaceholder")},null,8,gy),[[ot,ke(n).config.ffmpegPath]]),c("p",vy,E(a.$t("config.ffmpegPathHint")),1)]),c("div",null,[c("label",by,E(a.$t("config.delCache")),1),c("div",_y,[c("label",yy,[Fe(c("input",{"onUpdate:modelValue":i[4]||(i[4]=u=>ke(n).config.delCache=u),type:"checkbox",class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500"},null,512),[[Bn,ke(n).config.delCache]]),c("span",wy,E(a.$t("config.delCacheLabel")),1)])]),c("p",xy,E(a.$t("config.delCacheHint")),1)]),c("div",null,[c("label",Ey,E(a.$t("config.convert")),1),c("div",ky,[c("label",Cy,[Fe(c("input",{"onUpdate:modelValue":i[5]||(i[5]=u=>ke(n).config.convert=u),type:"checkbox",class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500"},null,512),[[Bn,ke(n).config.convert]]),c("span",Sy,E(a.$t("config.convertLabel")),1)])])]),c("div",null,[c("label",Ty,E(a.$t("config.showPreview")),1),c("div",Ly,[c("label",$y,[Fe(c("input",{"onUpdate:modelValue":i[6]||(i[6]=u=>ke(n).config.showPreview=u),type:"checkbox",class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500"},null,512),[[Bn,ke(n).config.showPreview]]),c("span",Ny,E(a.$t("config.showPreviewLabel")),1)])])]),c("div",null,[c("label",Iy,E(a.$t("config.showLocalPlay")),1),c("div",Py,[c("label",Ay,[Fe(c("input",{"onUpdate:modelValue":i[7]||(i[7]=u=>ke(n).config.showLocalPlay=u),type:"checkbox",class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500"},null,512),[[Bn,ke(n).config.showLocalPlay]]),c("span",Dy,E(a.$t("config.showLocalPlayLabel")),1)])])])]),c("div",Oy,[c("button",Ry,E(a.$t("config.save")),1)])],32)]),c("div",My,[c("h2",Fy,E(a.$t("config.localConfig")),1),c("form",{onSubmit:gn(r,["prevent"]),class:"space-y-6"},[c("div",Uy,[c("div",null,[c("label",Vy,E(a.$t("config.token")),1),c("div",Hy,[Fe(c("input",{"onUpdate:modelValue":i[8]||(i[8]=u=>s.value=u),type:"password",maxlength:"256",class:"w-full p-2 border rounded-lg focus:ring-blue-500",placeholder:a.$t("config.tokenPlaceholder")},null,8,Wy),[[ot,s.value]])]),c("p",jy,E(a.$t("config.tokenHint")),1)])]),c("div",By,[c("button",Gy,E(a.$t("config.save")),1)])],32)])])])]),_:1}))}}),Yy=Po(Ky,[["__scopeId","data-v-51fd32c8"]]),qy={class:"download-item p-4 hover:bg-gray-50 relative"},Xy={class:"flex items-center justify-between mb-2"},zy={class:"flex-1"},Qy={class:"flex items-center"},Jy=["checked","title"],Zy=["title"],ew={class:"absolute right-1 top-1 text-xs rounded overflow-hidden"},tw={key:0,class:"px-2 py-0.5 bg-yellow-100 text-yellow-800"},nw={key:1,class:"px-2 py-0.5 bg-green-100 text-green-800"},sw={key:2,class:"px-2 py-0.5 bg-gray-100 text-gray-800"},ow={key:3,class:"px-2 py-0.5 bg-blue-100 text-blue-800"},lw=["title"],rw={class:"flex items-center text-sm text-gray-500 mt-1 flex-wrap gap-2"},aw={key:2,class:"flex items-center"},iw={class:"flex items-center"},cw={key:3,class:"flex items-center"},uw={key:4,class:"flex items-center"},fw={class:"flex space-x-2"},dw=["title"],mw=["title"],pw=["title"],hw={class:"relative pt-1"},gw={class:"flex mb-2 items-center justify-between"},vw={class:"flex items-center"},bw={class:"text-xs font-semibold inline-block text-blue-600"},_w={class:"text-xs font-semibold inline-block py-1 px-2 rounded text-green-600"},yw={class:"overflow-hidden h-2 text-xs flex rounded bg-blue-200"},ww=Oe({__name:"TaskItem",props:{task:{},isSelected:{type:Boolean}},emits:["toggle-select","show-detail","preview","local-play","pause","resume","delete"],setup(e){const{t}=je(),n=ss(),s=fe(()=>n.config);return(l,o)=>(K(),Z("div",qy,[c("div",Xy,[c("div",zy,[c("div",Qy,[c("input",{type:"checkbox",checked:e.isSelected,onChange:o[0]||(o[0]=r=>l.$emit("toggle-select")),class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500 mr-2",title:l.$t("taskItem.selectTask",{name:e.task.showName})},null,40,Jy),c("h3",{class:"font-bold text-green-600 truncate max-w-[calc(100vw-100px)]",title:e.task.url},E(e.task.showName),9,Zy),c("div",ew,[e.task.status==="pending"?(K(),Z("span",tw,E(l.$t("download.status.pending")),1)):e.task.status==="resume"?(K(),Z("span",nw,E(l.$t("download.status.resume")),1)):e.task.status==="pause"?(K(),Z("span",sw,E(l.$t("download.status.pause")),1)):e.task.status==="done"?(K(),Z("span",ow,E(l.$t("download.status.done")),1)):e.task.status==="error"?(K(),Z("span",{key:4,class:"px-2 py-0.5 bg-red-100 text-red-600",title:e.task.errmsg},[_e(E(e.task.errmsg||l.$t("download.status.error"))+" ",1),o[7]||(o[7]=c("i",{class:"fas fa-info-circle"},null,-1))],8,lw)):se("",!0)])]),c("div",rw,[c("span",{class:"cursor-pointer text-blue-600 hover:text-blue-800",onClick:o[1]||(o[1]=r=>l.$emit("show-detail"))},[o[8]||(o[8]=c("i",{class:"fas fa-info-circle mr-1"},null,-1)),c("span",null,E(l.$t("taskItem.detail")),1)]),s.value?.showPreview?(K(),Z("span",{key:0,class:"text-blue-500 hover:text-blue-600 cursor-pointer",onClick:o[2]||(o[2]=r=>l.$emit("preview"))},[o[9]||(o[9]=c("i",{class:"fas fa-eye mr-1"},null,-1)),_e(E(l.$t("taskItem.preview")),1)])):se("",!0),s.value?.showLocalPlay?(K(),Z("span",{key:1,class:"text-green-500 hover:text-green-600 cursor-pointer",onClick:o[3]||(o[3]=r=>l.$emit("local-play"))},[o[10]||(o[10]=c("i",{class:"fas fa-play-circle mr-1"},null,-1)),_e(E(e.task.localVideo?l.$t("taskItem.play"):l.$t("taskItem.localPlay")),1)])):se("",!0),e.task.duration?(K(),Z("span",aw,[o[11]||(o[11]=c("i",{class:"fas fa-clock mr-1"},null,-1)),c("span",null,E(l.$t("taskItem.duration"))+": "+E(ke(uo)(e.task.duration*1e3)),1)])):se("",!0),c("span",iw,[o[12]||(o[12]=c("i",{class:"fas fa-file-video mr-1"},null,-1)),c("span",null,E(l.$t("taskItem.size"))+": "+E(ke(ts)(e.task.downloadedSize||0)),1)]),e.task.tsCount?(K(),Z("span",cw,[o[13]||(o[13]=c("i",{class:"fas fa-file-alt mr-1"},null,-1)),c("span",null,E(l.$t("taskItem.segments"))+": "+E((e.task.tsSuccess||0)+(e.task.tsFailed||0))+"/"+E(e.task.tsCount),1)])):se("",!0),e.task.status==="resume"?(K(),Z("span",uw,[o[14]||(o[14]=c("i",{class:"fas fa-hourglass-half mr-1"},null,-1)),c("span",null,E(l.$t("taskItem.remaining"))+": "+E(ke(uo)(e.task.remainingTime||0)),1)])):se("",!0)])]),c("div",fw,[e.task.status==="resume"||e.task.status==="pending"?(K(),Z("button",{key:0,onClick:o[4]||(o[4]=r=>l.$emit("pause")),class:"p-2 text-yellow-500 hover:bg-yellow-50 rounded",title:l.$t("taskItem.pause")},[...o[15]||(o[15]=[c("i",{class:"fas fa-pause"},null,-1)])],8,dw)):se("",!0),e.task.status==="pause"||e.task.status==="error"?(K(),Z("button",{key:1,onClick:o[5]||(o[5]=r=>l.$emit("resume")),class:"p-2 text-green-500 hover:bg-green-50 rounded",title:l.$t("taskItem.resume")},[...o[16]||(o[16]=[c("i",{class:"fas fa-play"},null,-1)])],8,mw)):se("",!0),c("button",{onClick:o[6]||(o[6]=r=>l.$emit("delete")),class:"p-2 text-red-500 hover:bg-red-50 rounded",title:l.$t("taskItem.delete")},[...o[17]||(o[17]=[c("i",{class:"fas fa-trash"},null,-1)])],8,pw)])]),c("div",hw,[c("div",gw,[c("div",vw,[c("span",bw,E(e.task.progress||0)+"% ",1)]),c("div",null,[c("span",_w,E(e.task.speedDesc),1)])]),c("div",yw,[c("div",{style:vo({width:(e.task.progress||0)+"%"}),class:"progress-bar shadow-none flex flex-col text-center whitespace-nowrap text-white justify-center bg-blue-500"},null,4)])])]))}}),xw={class:"p-8 text-center text-gray-500"},Ew=Oe({__name:"EmptyState",emits:["new-download"],setup(e){const{t}=je();return(n,s)=>(K(),Z("div",xw,[s[2]||(s[2]=c("i",{class:"fas fa-download text-4xl mb-4"},null,-1)),c("p",null,E(n.$t("emptyState.noTasks")),1),c("button",{onClick:s[0]||(s[0]=l=>n.$emit("new-download")),class:"mt-4 px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600"},[s[1]||(s[1]=c("i",{class:"fas fa-plus mr-1"},null,-1)),_e(E(n.$t("emptyState.addTask")),1)])]))}}),kw={class:"bg-white rounded-lg shadow"},Cw={class:"p-4"},Sw={class:"flex justify-between items-center"},Tw={class:"text-xl font-semibold"},Lw={class:"flex space-x-2"},$w={class:"mt-4 flex items-center space-x-4"},Nw={class:"flex-1"},Iw={class:"relative"},Pw=["placeholder","aria-label"],Aw={class:"flex items-center space-x-2"},Dw=["value","title","aria-label"],Ow={value:""},Rw={value:"resume"},Mw={value:"pending"},Fw={value:"pause"},Uw={value:"error"},Vw=["title","aria-label"],Hw={class:"text-sm text-gray-600 border-b bg-gray-50"},Ww={class:"flex items-center space-x-4 px-4 py-2"},jw={class:"flex items-center"},Bw=["checked","indeterminate","title"],Gw={class:"text-gray-700 text-sm"},Kw={class:"ml-4 text-gray-400 text-xs"},Yw={class:"flex items-center"},qw={class:"flex items-center"},Xw={class:"flex items-center"},zw={class:"divide-y overflow-auto max-h-[calc(100vh-200px)]"},Qw=Oe({__name:"TaskList",emits:["new-download","pause","resume","delete","clear-queue","show-detail","local-play"],setup(e,{emit:t}){const{t:n}=je(),s=Mn(),l=fe(()=>{const S=s.filteredTasks;return console.log("[TaskList] filteredTasks computed, 数量:",S.length),S}),o=fe(()=>s.selectedTasks),r=fe(()=>s.queueStatus),a=fe(()=>s.statusFilter),i=q(s.searchQuery);let u=null;mt(i,S=>{u&&clearTimeout(u),u=window.setTimeout(()=>{s.searchQuery=S},300)});const f=fe(()=>l.value.length>0&&o.value.length===l.value.length),d=fe(()=>o.value.length>0&&o.value.length<l.value.length);function m(S){const L=S.target;s.statusFilter=L.value}function g(){s.clearFilters()}function C(){s.toggleSelectAll()}function k(S){s.toggleTaskSelection(S)}const N=t;function O(S){N("pause",[S])}function I(S){N("resume",[S])}function b(S){N("delete",[S])}function v(S){N("show-detail",S)}function T(S){window.open(`https://lzw.me/x/m3u8-player/?url=${encodeURIComponent(S)}`)}function $(S){const L=S.localVideo||S.localM3u8;if(!L){console.error("[TaskList] localPlay: task 缺少本地文件路径",S),be({text:n("error.noLocalFile"),type:"error"});return}const x=location.origin+`/localplay/${L}`;N("local-play",{task:S,url:x})}return(S,L)=>(K(),Z("div",kw,[c("div",Cw,[c("div",Sw,[c("h2",Tw,E(S.$t("taskList.title")),1),c("div",Lw,[c("button",{onClick:L[0]||(L[0]=x=>S.$emit("new-download")),class:"px-3 py-1 text-sm bg-blue-500 hover:bg-blue-600 text-white rounded"},[L[9]||(L[9]=c("i",{class:"fas fa-plus mr-1"},null,-1)),_e(E(S.$t("taskList.new")),1)]),o.value.length>0?(K(),Z("button",{key:0,onClick:L[1]||(L[1]=x=>S.$emit("pause",o.value)),class:"px-3 py-1 text-sm bg-yellow-500 text-white rounded hover:bg-yellow-600"},[L[10]||(L[10]=c("i",{class:"fas fa-pause mr-1"},null,-1)),_e(E(S.$t("taskList.pauseSelected")),1)])):se("",!0),o.value.length>0?(K(),Z("button",{key:1,onClick:L[2]||(L[2]=x=>S.$emit("resume",o.value)),class:"px-3 py-1 text-sm bg-green-500 text-white rounded hover:bg-green-600"},[L[11]||(L[11]=c("i",{class:"fas fa-play mr-1"},null,-1)),_e(E(S.$t("taskList.resumeSelected")),1)])):se("",!0),o.value.length>0?(K(),Z("button",{key:2,onClick:L[3]||(L[3]=x=>S.$emit("delete",o.value)),class:"px-3 py-1 text-sm bg-red-500 text-white rounded hover:bg-red-600"},[L[12]||(L[12]=c("i",{class:"fas fa-trash mr-1"},null,-1)),_e(E(S.$t("taskList.deleteSelected")),1)])):se("",!0),o.value.length===0?(K(),Z("button",{key:3,onClick:L[4]||(L[4]=x=>S.$emit("pause","all")),class:"px-3 py-1 text-sm bg-yellow-500 text-white rounded hover:bg-yellow-600"},[L[13]||(L[13]=c("i",{class:"fas fa-pause mr-1"},null,-1)),_e(E(S.$t("taskList.pauseAll")),1)])):se("",!0),o.value.length===0?(K(),Z("button",{key:4,onClick:L[5]||(L[5]=x=>S.$emit("resume","all")),class:"px-3 py-1 text-sm bg-green-500 text-white rounded hover:bg-green-600"},[L[14]||(L[14]=c("i",{class:"fas fa-play mr-1"},null,-1)),_e(E(S.$t("taskList.resumeAll")),1)])):se("",!0),o.value.length===0?(K(),Z("button",{key:5,onClick:L[6]||(L[6]=x=>S.$emit("clear-queue")),class:"px-3 py-1 text-sm bg-red-500 text-white rounded hover:bg-red-600"},[L[15]||(L[15]=c("i",{class:"fas fa-trash mr-1"},null,-1)),_e(E(S.$t("taskList.clearQueue")),1)])):se("",!0)])]),c("div",$w,[c("div",Nw,[c("div",Iw,[Fe(c("input",{type:"text","onUpdate:modelValue":L[7]||(L[7]=x=>i.value=x),class:"w-full pl-10 pr-4 py-2 border rounded-lg focus:ring-blue-500 focus:border-blue-500",placeholder:S.$t("taskList.searchPlaceholder"),"aria-label":S.$t("taskList.searchLabel")},null,8,Pw),[[ot,i.value]]),L[16]||(L[16]=c("i",{class:"fas fa-search absolute left-3 top-3 text-gray-400"},null,-1))])]),c("div",Aw,[c("select",{value:a.value,onChange:m,class:"px-3 py-2 border rounded-lg focus:ring-blue-500 focus:border-blue-500",title:S.$t("taskList.filterByStatus"),"aria-label":S.$t("taskList.filterByStatus")},[c("option",Ow,E(S.$t("taskList.all")),1),c("option",Rw,E(S.$t("taskList.status.resume")),1),c("option",Mw,E(S.$t("taskList.status.pending")),1),c("option",Fw,E(S.$t("taskList.status.pause")),1),c("option",Uw,E(S.$t("taskList.status.error")),1)],40,Dw),c("button",{onClick:g,class:"px-3 py-2 text-gray-600 hover:text-gray-800",title:S.$t("taskList.clearFilters"),"aria-label":S.$t("taskList.clearFilters")},[...L[17]||(L[17]=[c("i",{class:"fas fa-times"},null,-1)])],8,Vw)])])]),c("div",Hw,[c("div",Ww,[c("div",jw,[c("input",{type:"checkbox",checked:f.value,indeterminate:d.value,onChange:C,class:"form-checkbox h-5 w-5 text-blue-500 rounded focus:ring-blue-500 mr-2",title:S.$t("taskList.selectAll")},null,40,Bw),c("span",Gw,E(S.$t("taskList.selectAll")),1),c("span",Kw,E(S.$t("taskList.selected"))+" "+E(o.value.length)+" / "+E(l.value.length),1)]),c("div",Yw,[L[18]||(L[18]=c("i",{class:"fas fa-tasks text-blue-600 mr-1"},null,-1)),c("span",null,E(S.$t("taskList.total"))+": "+E(l.value.length),1)]),c("div",qw,[L[19]||(L[19]=c("i",{class:"fas fa-clock text-yellow-500 mr-1"},null,-1)),c("span",null,E(S.$t("taskList.pending"))+": "+E(r.value.queueLength),1)]),c("div",Xw,[L[20]||(L[20]=c("i",{class:"fas fa-download text-green-500 mr-1"},null,-1)),c("span",null,E(S.$t("taskList.downloading"))+": "+E(r.value.activeDownloads.length),1)])])]),c("div",zw,[se("",!0),(K(!0),Z(Ge,null,xo(l.value,x=>(K(),Ut(ww,{key:x.url,task:x,"is-selected":o.value.includes(x.url),onToggleSelect:H=>k(x.url),onShowDetail:H=>v(x),onPreview:H=>T(x.url),onLocalPlay:H=>$(x),onPause:H=>O(x.url),onResume:H=>I(x.url),onDelete:H=>b(x.url)},null,8,["task","is-selected","onToggleSelect","onShowDetail","onPreview","onLocalPlay","onPause","onResume","onDelete"]))),128)),l.value.length===0?(K(),Ut(Ew,{key:1,onNewDownload:L[8]||(L[8]=x=>S.$emit("new-download"))})):se("",!0)])]))}}),Jw={class:"p-1 md:p-2"},Zw={key:0,class:"text-red-600 font-medium mb-2 whitespace-pre-line"},e1={class:"text-gray-600 whitespace-pre-line"},t1=Oe({__name:"Download",setup(e){const{t}=je(),n=Mn(),s=ss(),l=q(!1),o=q(!1),r=q(!1),a=q(!1),i=q(!1),u=q(null),f=q([]),d=q(null),m=q(""),g=q(""),C=q(""),k=q(null);Vt(async()=>{const{connect:M}=Jl(s.token||"");M();const P=Object.keys(n.tasks).length;if(P===0)try{console.log("[Download] store 中没有任务,开始获取任务列表...");const Y=await sm();console.log("[Download] 获取到的任务数据:",Y),Y&&typeof Y=="object"&&Object.keys(Y).length>0?(n.setTasks(Y),console.log("[Download] 任务数据已设置到 store,任务数量:",Object.keys(Y).length)):console.log("[Download] 获取到的任务数据为空,保留现有数据")}catch(Y){console.error("[Download] 获取任务列表失败:",Y)}else console.log(`[Download] store 中已有 ${P} 个任务,跳过获取`);H()});function N(){l.value=!0}async function O(M){const Y=await lm(M==="all"?["all"]:M,M==="all");Y.code||(be({text:Y.message||t("toast.pauseSuccess"),type:"success"}),Array.isArray(M)&&M===n.selectedTasks&&n.clearSelection())}async function I(M){const Y=await rm(M==="all"?["all"]:M,M==="all");Y.code||(be({text:Y.message||t("toast.resumeSuccess"),type:"success"}),Array.isArray(M)&&M===n.selectedTasks&&n.clearSelection())}function b(M){M.length&&(f.value=M,r.value=!0)}async function v(M){const P=await bc(f.value,M.deleteCache,M.deleteVideo);P.code||(be({text:P.message||t("toast.deleteSuccess"),type:"success"}),n.deleteTasks(f.value),f.value===n.selectedTasks&&n.clearSelection()),f.value=[]}async function T(){const M=await im();M.code?be({text:M.message||t("toast.clearQueueFailed"),type:"error"}):be({text:M.message||t("toast.clearQueueSuccess"),type:"success"})}function $(M){u.value=M,o.value=!0}function S(M){const{task:P,url:Y}=M;if(P.status==="error"){g.value=P.errmsg?t("confirm.playError",{error:P.errmsg}):"",m.value=t("confirm.playConfirmMessage"),d.value={task:P,url:Y},a.value=!0;return}x(Y,P)}function L(){d.value&&(x(d.value.url,d.value.task),d.value=null)}function x(M,P){C.value=M,k.value=P||null,i.value=!0}function H(){if(window.electron){const M=window.electron.ipc;M.on("message",P=>{typeof P.data=="string"?be({text:P.data,type:"info"}):console.log(P.data)}),M.on("downloadProgress",P=>{console.log("downloadProgress",P)})}}return(M,P)=>(K(),Ut(Vs,{onNewDownload:N},{default:Ft(()=>[c("div",Jw,[ye(Qw,{onNewDownload:N,onPause:O,onResume:I,onDelete:b,onClearQueue:T,onShowDetail:$,onLocalPlay:S}),ye(rr,{visible:l.value,onClose:P[0]||(P[0]=Y=>l.value=!1)},null,8,["visible"]),ye(fu,{visible:o.value,task:u.value,onClose:P[1]||(P[1]=Y=>o.value=!1)},null,8,["visible","task"]),ye(du,{visible:r.value,count:f.value.length,onClose:P[2]||(P[2]=Y=>r.value=!1),onConfirm:v},null,8,["visible","count"]),ye(mu,{visible:a.value,title:M.$t("confirm.play"),onClose:P[3]||(P[3]=Y=>a.value=!1),onConfirm:L},{default:Ft(()=>[g.value?(K(),Z("p",Zw,E(g.value),1)):se("",!0),c("p",e1,E(m.value),1)]),_:1},8,["visible","title"]),ye(pu,{visible:i.value,"initial-url":C.value,"initial-task":k.value,onClose:P[4]||(P[4]=Y=>i.value=!1)},null,8,["visible","initial-url","initial-task"])])]),_:1}))}}),n1={key:0,class:"web-browser-container border border-gray-300 rounded-lg p-4 mb-4 bg-white"},s1={class:"flex items-center justify-between mb-3"},o1={class:"text-lg font-semibold text-gray-800"},l1={class:"flex gap-2"},r1={class:"flex gap-2 mb-3"},a1=["placeholder","disabled"],i1=["disabled"],c1={key:0,class:"mb-3 p-2 bg-gray-50 rounded border border-gray-200"},u1={class:"flex items-center gap-2 mb-2"},f1=["disabled","title"],d1=["disabled","title"],m1=["title"],p1=["title"],h1={key:0,class:"text-xs text-gray-500"},g1={key:1,class:"mb-3 p-3 bg-red-50 border border-red-200 rounded text-red-700 text-sm"},v1={key:2,class:"mt-4"},b1={class:"flex items-center justify-between mb-2"},_1={class:"flex items-center gap-3"},y1={class:"text-sm font-semibold text-gray-700"},w1={class:"flex items-center gap-1 text-sm text-gray-600 cursor-pointer"},x1=["checked"],E1={key:0,class:"text-sm text-blue-600 font-medium"},k1={class:"flex gap-2"},C1={class:"border border-gray-200 rounded-lg overflow-hidden max-h-96 overflow-y-auto"},S1={class:"flex items-start gap-3"},T1=["checked","onChange"],L1=["onClick"],$1={class:"flex items-center gap-2 mb-1"},N1=["title"],I1=["title"],P1=["title"],A1=["title"],D1=["onClick"],O1={key:3,class:"text-sm text-gray-500 text-center py-4"},R1=Oe({__name:"WebBrowser",props:{visible:{type:Boolean}},emits:["batch-download"],setup(e,{emit:t}){const{t:n}=je(),s=t,l=fe(()=>typeof window<"u"&&!!window.electron),o=q(""),r=q(!1),a=q(""),i=q(""),u=q(""),f=q(!1),d=q(!1),m=q(!1),g=q([]),C=q(new Set);function k(){const B=o.value.trim();if(!B){be({text:n("webBrowser.enterUrl"),type:"error"});return}if(!/^https?:\/\//.test(B)){be({text:n("webBrowser.enterValidUrl"),type:"error"});return}if(!l.value){be({text:n("webBrowser.electronOnly"),type:"error"});return}r.value=!0,a.value="",i.value="",u.value=B,f.value=!0,window.electron?.ipc.send("web-browser:load",B)}function N(){l.value&&window.electron?.ipc.send("web-browser:stop"),r.value=!1}function O(){g.value=[],C.value.clear()}function I(B){s("batch-download",[{url:B.url,title:B.title||n("webBrowser.unnamedVideo")}])}function b(B){return C.value.has(B)}function v(B){C.value.has(B)?C.value.delete(B):C.value.add(B)}function T(B){B.target.checked?C.value=new Set(g.value.map((ve,F)=>F)):C.value.clear()}const $=fe(()=>g.value.length>0&&C.value.size===g.value.length),S=fe(()=>C.value.size);function L(){if(C.value.size===0){be({text:n("webBrowser.selectAtLeastOne"),type:"error"});return}const B=Array.from(C.value).map(le=>g.value[le]).map(le=>({url:le.url,title:le.title||n("webBrowser.unnamedVideo")}));s("batch-download",B),C.value.clear()}function x(B){return/\.m3u8(\?|$|#)/i.test(B)?"m3u8":/\.mp4(\?|$|#)/i.test(B)?"mp4":"video"}function H(B){try{const le=new URL(B);return`${le.protocol}//${le.host}${le.pathname}`}catch{return B}}function M(B){const le=H(B.url);g.value.some(F=>H(F.url)===le)||(g.value.push({url:B.url,title:B.title||i.value||n("webBrowser.unnamedVideo"),pageUrl:B.pageUrl||u.value}),be({text:n("webBrowser.newVideoFound",{title:B.title||n("webBrowser.unnamedVideo")}),type:"success"}))}function P(B){i.value=B,g.value.forEach(le=>{(!le.title||le.title===n("webBrowser.unnamedVideo"))&&(le.title=B||n("webBrowser.unnamedVideo"))})}function Y(B){u.value=B}function Se(B){u.value=B.url}function Re(){f.value=!1,u.value="",i.value="",d.value=!1,m.value=!1}function de(B){d.value=B.canGoBack,m.value=B.canGoForward}function ae(){l.value&&(window.electron?.ipc.send("web-browser:show"),f.value=!0)}function pe(){l.value&&(window.electron?.ipc.send("web-browser:hide"),f.value=!1)}function Xe(){l.value&&window.electron?.ipc.send("web-browser:go-back")}function tt(){l.value&&window.electron?.ipc.send("web-browser:go-forward")}function Ae(){l.value&&window.electron?.ipc.send("web-browser:reload")}function De(B){r.value=B.loading,B.loading||(g.value.length===0?be({text:n("webBrowser.pageLoadCompleteNoVideos"),type:"info"}):be({text:n("webBrowser.pageLoadComplete",{count:g.value.length}),type:"success"}))}function pt(B){a.value=`${n("error.requestFailed")}: ${B.description||`${n("error.unknownError")} ${B.code}`}`,r.value=!1,be({text:a.value,type:"error"})}return Vt(()=>{if(l.value&&window.electron){const B=window.electron.ipc;B.on("web-browser:m3u8-found",M),B.on("web-browser:page-title",P),B.on("web-browser:loading",De),B.on("web-browser:error",pt),B.on("web-browser:url-changed",Y),B.on("web-browser:navigation",Se),B.on("web-browser:closed",Re),B.on("web-browser:navigation-state",de)}}),On(()=>{if(l.value&&window.electron){const B=window.electron.ipc;B.removeAllListeners("web-browser:m3u8-found"),B.removeAllListeners("web-browser:page-title"),B.removeAllListeners("web-browser:loading"),B.removeAllListeners("web-browser:error"),B.removeAllListeners("web-browser:url-changed"),B.removeAllListeners("web-browser:navigation"),B.removeAllListeners("web-browser:closed"),B.removeAllListeners("web-browser:navigation-state")}}),(B,le)=>l.value?(K(),Z("div",n1,[c("div",s1,[c("h3",o1,[le[2]||(le[2]=c("i",{class:"fas fa-globe mr-2"},null,-1)),_e(E(B.$t("webBrowser.title")),1)]),c("div",l1,[f.value?(K(),Z("button",{key:0,onClick:pe,class:"px-3 py-1 bg-gray-500 text-white rounded hover:bg-gray-600 text-sm"},[le[3]||(le[3]=c("i",{class:"fas fa-eye-slash mr-1"},null,-1)),_e(E(B.$t("webBrowser.hideBrowser")),1)])):u.value?(K(),Z("button",{key:1,onClick:ae,class:"px-3 py-1 bg-green-500 text-white rounded hover:bg-green-600 text-sm"},[le[4]||(le[4]=c("i",{class:"fas fa-eye mr-1"},null,-1)),_e(E(B.$t("webBrowser.showBrowser")),1)])):se("",!0),r.value?(K(),Z("button",{key:2,onClick:N,class:"px-3 py-1 bg-red-500 text-white rounded hover:bg-red-600 text-sm"},[le[5]||(le[5]=c("i",{class:"fas fa-stop mr-1"},null,-1)),_e(E(B.$t("webBrowser.stop")),1)])):se("",!0)])]),c("div",r1,[Fe(c("input",{"onUpdate:modelValue":le[0]||(le[0]=ve=>o.value=ve),type:"text",placeholder:B.$t("webBrowser.urlPlaceholder"),class:"flex-1 border border-gray-300 rounded px-3 py-2 focus:outline-none focus:ring-2 focus:ring-blue-400",disabled:r.value,onKeyup:ql(k,["enter"])},null,40,a1),[[ot,o.value]]),c("button",{onClick:k,disabled:r.value||!o.value.trim(),class:"px-4 py-2 bg-blue-600 text-white rounded hover:bg-blue-700 focus:outline-none disabled:opacity-50 disabled:cursor-not-allowed"},E(r.value?B.$t("webBrowser.loading"):B.$t("webBrowser.load")),9,i1)]),u.value?(K(),Z("div",c1,[c("div",u1,[c("button",{onClick:Xe,disabled:!d.value,class:"px-2 py-1 bg-white border border-gray-300 rounded hover:bg-gray-50 disabled:opacity-50 disabled:cursor-not-allowed",title:B.$t("common.back")},[...le[6]||(le[6]=[c("i",{class:"fas fa-arrow-left"},null,-1)])],8,f1),c("button",{onClick:tt,disabled:!m.value,class:"px-2 py-1 bg-white border border-gray-300 rounded hover:bg-gray-50 disabled:opacity-50 disabled:cursor-not-allowed",title:B.$t("common.forward")},[...le[7]||(le[7]=[c("i",{class:"fas fa-arrow-right"},null,-1)])],8,d1),c("button",{onClick:Ae,class:"px-2 py-1 bg-white border border-gray-300 rounded hover:bg-gray-50",title:B.$t("common.refresh")},[...le[8]||(le[8]=[c("i",{class:"fas fa-sync-alt"},null,-1)])],8,m1),c("div",{class:"flex-1 text-xs text-gray-600 truncate ml-2",title:u.value},[le[9]||(le[9]=c("i",{class:"fas fa-link mr-1"},null,-1)),_e(E(u.value),1)],8,p1)]),i.value?(K(),Z("div",h1,[le[10]||(le[10]=c("i",{class:"fas fa-file-alt mr-1"},null,-1)),_e(E(i.value),1)])):se("",!0)])):se("",!0),a.value?(K(),Z("div",g1,[le[11]||(le[11]=c("i",{class:"fas fa-exclamation-circle mr-2"},null,-1)),_e(E(a.value),1)])):se("",!0),g.value.length>0?(K(),Z("div",v1,[c("div",b1,[c("div",_1,[c("h4",y1,E(B.$t("webBrowser.foundVideos",{count:g.value.length})),1),c("label",w1,[c("input",{type:"checkbox",checked:$.value,onChange:T,class:"rounded border-gray-300 text-blue-600 focus:ring-blue-500"},null,40,x1),c("span",null,E(B.$t("download.selectAll")),1)]),S.value>0?(K(),Z("span",E1,E(B.$t("download.selected"))+" "+E(S.value),1)):se("",!0)]),c("div",k1,[S.value>0?(K(),Z("button",{key:0,onClick:L,class:"px-3 py-1 bg-green-500 text-white rounded hover:bg-green-600 text-sm"},E(B.$t("download.batchDownload"))+" ("+E(S.value)+") ",1)):se("",!0),c("button",{onClick:O,class:"text-sm text-gray-500 hover:text-gray-700"},E(B.$t("webBrowser.clearList")),1)])]),c("div",C1,[(K(!0),Z(Ge,null,xo(g.value,(ve,F)=>(K(),Z("div",{key:F,class:Qe(["p-3 border-b border-gray-100 hover:bg-gray-50 transition-colors",{"bg-blue-50":b(F)}])},[c("div",S1,[c("input",{type:"checkbox",checked:b(F),onChange:ee=>v(F),onClick:le[1]||(le[1]=gn(()=>{},["stop"])),class:"mt-1 rounded border-gray-300 text-blue-600 focus:ring-blue-500"},null,40,T1),c("div",{class:"flex-1 min-w-0 cursor-pointer",onClick:ee=>I(ve)},[c("div",$1,[c("div",{class:"text-sm font-medium text-gray-800 truncate",title:ve.title},E(ve.title||B.$t("webBrowser.unnamedVideo")),9,N1),c("span",{class:"text-xs px-2 py-0.5 bg-blue-100 text-blue-700 rounded",title:x(ve.url)},E(x(ve.url).toUpperCase()),9,I1)]),c("div",{class:"text-xs text-gray-500 truncate",title:ve.url},E(ve.url),9,P1),ve.pageUrl&&ve.pageUrl!==u.value?(K(),Z("div",{key:0,class:"text-xs text-gray-400 mt-1 truncate",title:ve.pageUrl},E(B.$t("webBrowser.source"))+": "+E(ve.pageUrl),9,A1)):se("",!0)],8,L1),c("button",{onClick:gn(ee=>I(ve),["stop"]),class:"ml-2 px-3 py-1 bg-blue-500 text-white rounded hover:bg-blue-600 text-sm whitespace-nowrap"},E(B.$t("webBrowser.download")),9,D1)])],2))),128))])])):!r.value&&o.value?(K(),Z("div",O1,E(B.$t("webBrowser.noVideos")),1)):se("",!0)])):se("",!0)}}),M1=Po(R1,[["__scopeId","data-v-8ef86d80"]]),F1={class:"p-1 md:p-2"},U1=Oe({__name:"WebBrowser",setup(e){const t=q(!1),n=q(void 0);function s(o){const r=o.map(a=>a.title?`${a.url} | ${a.title}`:a.url).join(`
|
|
25
|
+
`);n.value={url:r},t.value=!0}function l(){t.value=!1,n.value=void 0}return(o,r)=>(K(),Ut(Vs,null,{default:Ft(()=>[c("div",F1,[ye(M1,{onBatchDownload:s}),ye(rr,{visible:t.value,"initial-data":n.value,onClose:l},null,8,["visible","initial-data"])])]),_:1}))}}),V1=wv({history:Zg(),routes:[{path:"/",redirect:"/page/download"},{path:"/page/download",name:"download",component:t1},{path:"/page/web-browser",name:"web-browser",component:U1},{path:"/page/completed",name:"completed",component:Z0},{path:"/page/config",name:"config",component:Yy},{path:"/page/about",name:"about",component:fb}]}),Ao=Bd(ug),H1=Yd();Ao.use(H1);Ao.use(V1);Ao.use(pg);Ao.mount("#app");
|