gear-second 3.5.1 → 3.6.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/index.js +7 -7
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(rt,me){typeof exports=="object"&&typeof module<"u"?module.exports=me():typeof define=="function"&&define.amd?define(me):(rt=typeof globalThis<"u"?globalThis:rt||self,rt._gearSecond_=me())})(this,function(){"use strict";var C0=Object.defineProperty;var T0=(rt,me,bt)=>me in rt?C0(rt,me,{enumerable:!0,configurable:!0,writable:!0,value:bt}):rt[me]=bt;var ie=(rt,me,bt)=>T0(rt,typeof me!="symbol"?me+"":me,bt);/**
|
|
2
2
|
* @vue/shared v3.5.24
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
|
-
**/function
|
|
5
|
+
**/function rt(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const me={},bt=[],Ct=()=>{},Or=()=>!1,lo=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),ai=e=>e.startsWith("onUpdate:"),$e=Object.assign,ci=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},ic=Object.prototype.hasOwnProperty,Ce=(e,t)=>ic.call(e,t),le=Array.isArray,xn=e=>Dn(e)==="[object Map]",ao=e=>Dn(e)==="[object Set]",$r=e=>Dn(e)==="[object Date]",he=e=>typeof e=="function",De=e=>typeof e=="string",yt=e=>typeof e=="symbol",Ie=e=>e!==null&&typeof e=="object",Dr=e=>(Ie(e)||he(e))&&he(e.then)&&he(e.catch),zr=Object.prototype.toString,Dn=e=>zr.call(e),rc=e=>Dn(e).slice(8,-1),co=e=>Dn(e)==="[object Object]",ui=e=>De(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,zn=rt(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),uo=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},sc=/-\w/g,Fe=uo(e=>e.replace(sc,t=>t.slice(1).toUpperCase())),lc=/\B([A-Z])/g,et=uo(e=>e.replace(lc,"-$1").toLowerCase()),fo=uo(e=>e.charAt(0).toUpperCase()+e.slice(1)),di=uo(e=>e?`on${fo(e)}`:""),tt=(e,t)=>!Object.is(e,t),po=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},Ar=(e,t,n,o=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:o,value:n})},fi=e=>{const t=parseFloat(e);return isNaN(t)?e:t},pi=e=>{const t=De(e)?Number(e):NaN;return isNaN(t)?e:t};let Br;const ho=()=>Br||(Br=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Te(e){if(le(e)){const t={};for(let n=0;n<e.length;n++){const o=e[n],i=De(o)?dc(o):Te(o);if(i)for(const r in i)t[r]=i[r]}return t}else if(De(e)||Ie(e))return e}const ac=/;(?![^(]*\))/g,cc=/:([^]+)/,uc=/\/\*[^]*?\*\//g;function dc(e){const t={};return e.replace(uc,"").split(ac).forEach(n=>{if(n){const o=n.split(cc);o.length>1&&(t[o[0].trim()]=o[1].trim())}}),t}function de(e){let t="";if(De(e))t=e;else if(le(e))for(let n=0;n<e.length;n++){const o=de(e[n]);o&&(t+=o+" ")}else if(Ie(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const fc=rt("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function Lr(e){return!!e||e===""}function pc(e,t){if(e.length!==t.length)return!1;let n=!0;for(let o=0;n&&o<e.length;o++)n=go(e[o],t[o]);return n}function go(e,t){if(e===t)return!0;let n=$r(e),o=$r(t);if(n||o)return n&&o?e.getTime()===t.getTime():!1;if(n=yt(e),o=yt(t),n||o)return e===t;if(n=le(e),o=le(t),n||o)return n&&o?pc(e,t):!1;if(n=Ie(e),o=Ie(t),n||o){if(!n||!o)return!1;const i=Object.keys(e).length,r=Object.keys(t).length;if(i!==r)return!1;for(const s in e){const l=e.hasOwnProperty(s),a=t.hasOwnProperty(s);if(l&&!a||!l&&a||!go(e[s],t[s]))return!1}}return String(e)===String(t)}function jr(e,t){return e.findIndex(n=>go(n,t))}const Nr=e=>!!(e&&e.__v_isRef===!0),We=e=>De(e)?e:e==null?"":le(e)||Ie(e)&&(e.toString===zr||!he(e.toString))?Nr(e)?We(e.value):JSON.stringify(e,Vr,2):String(e),Vr=(e,t)=>Nr(t)?Vr(e,t.value):xn(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[o,i],r)=>(n[hi(o,r)+" =>"]=i,n),{})}:ao(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>hi(n))}:yt(t)?hi(t):Ie(t)&&!le(t)&&!co(t)?String(t):t,hi=(e,t="")=>{var n;return yt(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
|
|
6
6
|
* @vue/reactivity v3.5.24
|
|
7
7
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
8
8
|
* @license MIT
|
|
9
|
-
**/let We;class tc{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=We,!t&&We&&(this.index=(We.scopes||(We.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=We;try{return We=this,t()}finally{We=n}}}on(){++this._on===1&&(this.prevScope=We,We=this)}off(){this._on>0&&--this._on===0&&(We=this.prevScope,this.prevScope=void 0)}stop(t){if(this._active){this._active=!1;let n,o;for(n=0,o=this.effects.length;n<o;n++)this.effects[n].stop();for(this.effects.length=0,n=0,o=this.cleanups.length;n<o;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){for(n=0,o=this.scopes.length;n<o;n++)this.scopes[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const i=this.parent.scopes.pop();i&&i!==this&&(this.parent.scopes[this.index]=i,i.index=this.index)}this.parent=void 0}}}function pi(){return We}function nc(e,t=!1){We&&We.cleanups.push(e)}let Ee;const hi=new WeakSet;class Ar{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,We&&We.active&&We.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,hi.has(this)&&(hi.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||jr(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Hr(this),Br(this);const t=Ee,n=yt;Ee=this,yt=!0;try{return this.fn()}finally{Nr(this),Ee=t,yt=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)bi(t);this.deps=this.depsTail=void 0,Hr(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?hi.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){vi(this)&&this.run()}get dirty(){return vi(this)}}let Lr=0,On,$n;function jr(e,t=!1){if(e.flags|=8,t){e.next=$n,$n=e;return}e.next=On,On=e}function gi(){Lr++}function mi(){if(--Lr>0)return;if($n){let t=$n;for($n=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;On;){let t=On;for(On=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(o){e||(e=o)}t=n}}if(e)throw e}function Br(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Nr(e){let t,n=e.depsTail,o=n;for(;o;){const i=o.prevDep;o.version===-1?(o===n&&(n=i),bi(o),oc(o)):t=o,o.dep.activeLink=o.prevActiveLink,o.prevActiveLink=void 0,o=i}e.deps=t,e.depsTail=n}function vi(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Vr(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Vr(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===zn)||(e.globalVersion=zn,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!vi(e))))return;e.flags|=2;const t=e.dep,n=Ee,o=yt;Ee=e,yt=!0;try{Br(e);const i=e.fn(e._value);(t.version===0||et(i,e._value))&&(e.flags|=128,e._value=i,t.version++)}catch(i){throw t.version++,i}finally{Ee=n,yt=o,Nr(e),e.flags&=-3}}function bi(e,t=!1){const{dep:n,prevSub:o,nextSub:i}=e;if(o&&(o.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=o,e.nextSub=void 0),n.subs===e&&(n.subs=o,!o&&n.computed)){n.computed.flags&=-5;for(let r=n.computed.deps;r;r=r.nextDep)bi(r,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function oc(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let yt=!0;const Rr=[];function Ct(){Rr.push(yt),yt=!1}function Tt(){const e=Rr.pop();yt=e===void 0?!0:e}function Hr(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=Ee;Ee=void 0;try{t()}finally{Ee=n}}}let zn=0;class ic{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 go{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(!Ee||!yt||Ee===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==Ee)n=this.activeLink=new ic(Ee,this),Ee.deps?(n.prevDep=Ee.depsTail,Ee.depsTail.nextDep=n,Ee.depsTail=n):Ee.deps=Ee.depsTail=n,Fr(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const o=n.nextDep;o.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=o),n.prevDep=Ee.depsTail,n.nextDep=void 0,Ee.depsTail.nextDep=n,Ee.depsTail=n,Ee.deps===n&&(Ee.deps=o)}return n}trigger(t){this.version++,zn++,this.notify(t)}notify(t){gi();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{mi()}}}function Fr(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let o=t.deps;o;o=o.nextDep)Fr(o)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const mo=new WeakMap,rn=Symbol(""),yi=Symbol(""),Dn=Symbol("");function Ue(e,t,n){if(yt&&Ee){let o=mo.get(e);o||mo.set(e,o=new Map);let i=o.get(n);i||(o.set(n,i=new go),i.map=o,i.key=n),i.track()}}function Bt(e,t,n,o,i,r){const s=mo.get(e);if(!s){zn++;return}const l=a=>{a&&a.trigger()};if(gi(),t==="clear")s.forEach(l);else{const a=re(e),u=a&&ai(n);if(a&&n==="length"){const c=Number(o);s.forEach((d,f)=>{(f==="length"||f===Dn||!bt(f)&&f>=c)&&l(d)})}else switch((n!==void 0||s.has(void 0))&&l(s.get(n)),u&&l(s.get(Dn)),t){case"add":a?u&&l(s.get("length")):(l(s.get(rn)),vn(e)&&l(s.get(yi)));break;case"delete":a||(l(s.get(rn)),vn(e)&&l(s.get(yi)));break;case"set":vn(e)&&l(s.get(rn));break}}mi()}function rc(e,t){const n=mo.get(e);return n&&n.get(t)}function bn(e){const t=xe(e);return t===e?t:(Ue(t,"iterate",Dn),ut(e)?t:t.map(Ne))}function vo(e){return Ue(e=xe(e),"iterate",Dn),e}const sc={__proto__:null,[Symbol.iterator](){return wi(this,Symbol.iterator,Ne)},concat(...e){return bn(this).concat(...e.map(t=>re(t)?bn(t):t))},entries(){return wi(this,"entries",e=>(e[1]=Ne(e[1]),e))},every(e,t){return Nt(this,"every",e,t,void 0,arguments)},filter(e,t){return Nt(this,"filter",e,t,n=>n.map(Ne),arguments)},find(e,t){return Nt(this,"find",e,t,Ne,arguments)},findIndex(e,t){return Nt(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return Nt(this,"findLast",e,t,Ne,arguments)},findLastIndex(e,t){return Nt(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return Nt(this,"forEach",e,t,void 0,arguments)},includes(...e){return xi(this,"includes",e)},indexOf(...e){return xi(this,"indexOf",e)},join(e){return bn(this).join(e)},lastIndexOf(...e){return xi(this,"lastIndexOf",e)},map(e,t){return Nt(this,"map",e,t,void 0,arguments)},pop(){return An(this,"pop")},push(...e){return An(this,"push",e)},reduce(e,...t){return Wr(this,"reduce",e,t)},reduceRight(e,...t){return Wr(this,"reduceRight",e,t)},shift(){return An(this,"shift")},some(e,t){return Nt(this,"some",e,t,void 0,arguments)},splice(...e){return An(this,"splice",e)},toReversed(){return bn(this).toReversed()},toSorted(e){return bn(this).toSorted(e)},toSpliced(...e){return bn(this).toSpliced(...e)},unshift(...e){return An(this,"unshift",e)},values(){return wi(this,"values",Ne)}};function wi(e,t,n){const o=vo(e),i=o[t]();return o!==e&&!ut(e)&&(i._next=i.next,i.next=()=>{const r=i._next();return r.done||(r.value=n(r.value)),r}),i}const lc=Array.prototype;function Nt(e,t,n,o,i,r){const s=vo(e),l=s!==e&&!ut(e),a=s[t];if(a!==lc[t]){const d=a.apply(e,r);return l?Ne(d):d}let u=n;s!==e&&(l?u=function(d,f){return n.call(this,Ne(d),f,e)}:n.length>2&&(u=function(d,f){return n.call(this,d,f,e)}));const c=a.call(s,u,o);return l&&i?i(c):c}function Wr(e,t,n,o){const i=vo(e);let r=n;return i!==e&&(ut(e)?n.length>3&&(r=function(s,l,a){return n.call(this,s,l,a,e)}):r=function(s,l,a){return n.call(this,s,Ne(l),a,e)}),i[t](r,...o)}function xi(e,t,n){const o=xe(e);Ue(o,"iterate",Dn);const i=o[t](...n);return(i===-1||i===!1)&&Si(n[0])?(n[0]=xe(n[0]),o[t](...n)):i}function An(e,t,n=[]){Ct(),gi();const o=xe(e)[t].apply(e,n);return mi(),Tt(),o}const ac=it("__proto__,__v_isRef,__isVue"),Ur=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(bt));function cc(e){bt(e)||(e=String(e));const t=xe(this);return Ue(t,"has",e),t.hasOwnProperty(e)}class qr{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,o){if(n==="__v_skip")return t.__v_skip;const i=this._isReadonly,r=this._isShallow;if(n==="__v_isReactive")return!i;if(n==="__v_isReadonly")return i;if(n==="__v_isShallow")return r;if(n==="__v_raw")return o===(i?r?Jr:Gr:r?Xr:Yr).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(o)?t:void 0;const s=re(t);if(!i){let a;if(s&&(a=sc[n]))return a;if(n==="hasOwnProperty")return cc}const l=Reflect.get(t,n,ze(t)?t:o);if((bt(n)?Ur.has(n):ac(n))||(i||Ue(t,"get",n),r))return l;if(ze(l)){const a=s&&ai(n)?l:l.value;return i&&Te(a)?Ln(a):a}return Te(l)?i?Ln(l):xo(l):l}}class Kr extends qr{constructor(t=!1){super(!1,t)}set(t,n,o,i){let r=t[n];if(!this._isShallow){const a=Zt(r);if(!ut(o)&&!Zt(o)&&(r=xe(r),o=xe(o)),!re(t)&&ze(r)&&!ze(o))return a||(r.value=o),!0}const s=re(t)&&ai(n)?Number(n)<t.length:ke(t,n),l=Reflect.set(t,n,o,ze(t)?t:i);return t===xe(i)&&(s?et(o,r)&&Bt(t,"set",n,o):Bt(t,"add",n,o)),l}deleteProperty(t,n){const o=ke(t,n);t[n];const i=Reflect.deleteProperty(t,n);return i&&o&&Bt(t,"delete",n,void 0),i}has(t,n){const o=Reflect.has(t,n);return(!bt(n)||!Ur.has(n))&&Ue(t,"has",n),o}ownKeys(t){return Ue(t,"iterate",re(t)?"length":rn),Reflect.ownKeys(t)}}class Zr extends qr{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const uc=new Kr,dc=new Zr,fc=new Kr(!0),pc=new Zr(!0),_i=e=>e,bo=e=>Reflect.getPrototypeOf(e);function hc(e,t,n){return function(...o){const i=this.__v_raw,r=xe(i),s=vn(r),l=e==="entries"||e===Symbol.iterator&&s,a=e==="keys"&&s,u=i[e](...o),c=n?_i:t?So:Ne;return!t&&Ue(r,"iterate",a?yi:rn),{next(){const{value:d,done:f}=u.next();return f?{value:d,done:f}:{value:l?[c(d[0]),c(d[1])]:c(d),done:f}},[Symbol.iterator](){return this}}}}function yo(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function gc(e,t){const n={get(i){const r=this.__v_raw,s=xe(r),l=xe(i);e||(et(i,l)&&Ue(s,"get",i),Ue(s,"get",l));const{has:a}=bo(s),u=t?_i:e?So:Ne;if(a.call(s,i))return u(r.get(i));if(a.call(s,l))return u(r.get(l));r!==s&&r.get(i)},get size(){const i=this.__v_raw;return!e&&Ue(xe(i),"iterate",rn),i.size},has(i){const r=this.__v_raw,s=xe(r),l=xe(i);return e||(et(i,l)&&Ue(s,"has",i),Ue(s,"has",l)),i===l?r.has(i):r.has(i)||r.has(l)},forEach(i,r){const s=this,l=s.__v_raw,a=xe(l),u=t?_i:e?So:Ne;return!e&&Ue(a,"iterate",rn),l.forEach((c,d)=>i.call(r,u(c),u(d),s))}};return Oe(n,e?{add:yo("add"),set:yo("set"),delete:yo("delete"),clear:yo("clear")}:{add(i){!t&&!ut(i)&&!Zt(i)&&(i=xe(i));const r=xe(this);return bo(r).has.call(r,i)||(r.add(i),Bt(r,"add",i,i)),this},set(i,r){!t&&!ut(r)&&!Zt(r)&&(r=xe(r));const s=xe(this),{has:l,get:a}=bo(s);let u=l.call(s,i);u||(i=xe(i),u=l.call(s,i));const c=a.call(s,i);return s.set(i,r),u?et(r,c)&&Bt(s,"set",i,r):Bt(s,"add",i,r),this},delete(i){const r=xe(this),{has:s,get:l}=bo(r);let a=s.call(r,i);a||(i=xe(i),a=s.call(r,i)),l&&l.call(r,i);const u=r.delete(i);return a&&Bt(r,"delete",i,void 0),u},clear(){const i=xe(this),r=i.size!==0,s=i.clear();return r&&Bt(i,"clear",void 0,void 0),s}}),["keys","values","entries",Symbol.iterator].forEach(i=>{n[i]=hc(i,e,t)}),n}function wo(e,t){const n=gc(e,t);return(o,i,r)=>i==="__v_isReactive"?!e:i==="__v_isReadonly"?e:i==="__v_raw"?o:Reflect.get(ke(n,i)&&i in o?n:o,i,r)}const mc={get:wo(!1,!1)},vc={get:wo(!1,!0)},bc={get:wo(!0,!1)},yc={get:wo(!0,!0)},Yr=new WeakMap,Xr=new WeakMap,Gr=new WeakMap,Jr=new WeakMap;function wc(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function xc(e){return e.__v_skip||!Object.isExtensible(e)?0:wc(qa(e))}function xo(e){return Zt(e)?e:_o(e,!1,uc,mc,Yr)}function _c(e){return _o(e,!1,fc,vc,Xr)}function Ln(e){return _o(e,!0,dc,bc,Gr)}function Km(e){return _o(e,!0,pc,yc,Jr)}function _o(e,t,n,o,i){if(!Te(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const r=xc(e);if(r===0)return e;const s=i.get(e);if(s)return s;const l=new Proxy(e,r===2?o:n);return i.set(e,l),l}function yn(e){return Zt(e)?yn(e.__v_raw):!!(e&&e.__v_isReactive)}function Zt(e){return!!(e&&e.__v_isReadonly)}function ut(e){return!!(e&&e.__v_isShallow)}function Si(e){return e?!!e.__v_raw:!1}function xe(e){const t=e&&e.__v_raw;return t?xe(t):e}function Sc(e){return!ke(e,"__v_skip")&&Object.isExtensible(e)&&Er(e,"__v_skip",!0),e}const Ne=e=>Te(e)?xo(e):e,So=e=>Te(e)?Ln(e):e;function ze(e){return e?e.__v_isRef===!0:!1}function te(e){return Qr(e,!1)}function dt(e){return Qr(e,!0)}function Qr(e,t){return ze(e)?e:new kc(e,t)}class kc{constructor(t,n){this.dep=new go,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:xe(t),this._value=n?t:Ne(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,o=this.__v_isShallow||ut(t)||Zt(t);t=o?t:xe(t),et(t,n)&&(this._rawValue=t,this._value=o?t:Ne(t),this.dep.trigger())}}function X(e){return ze(e)?e.value:e}function ft(e){return pe(e)?e():X(e)}const Cc={get:(e,t,n)=>t==="__v_raw"?e:X(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const i=e[t];return ze(i)&&!ze(n)?(i.value=n,!0):Reflect.set(e,t,n,o)}};function es(e){return yn(e)?e:new Proxy(e,Cc)}class Tc{constructor(t){this.__v_isRef=!0,this._value=void 0;const n=this.dep=new go,{get:o,set:i}=t(n.track.bind(n),n.trigger.bind(n));this._get=o,this._set=i}get value(){return this._value=this._get()}set value(t){this._set(t)}}function ts(e){return new Tc(e)}class Mc{constructor(t,n,o){this._object=t,this._key=n,this._defaultValue=o,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 rc(xe(this._object),this._key)}}class Pc{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function Ec(e,t,n){return ze(e)?e:pe(e)?new Pc(e):Te(e)&&arguments.length>1?Ic(e,t,n):te(e)}function Ic(e,t,n){const o=e[t];return ze(o)?o:new Mc(e,t,n)}class Oc{constructor(t,n,o){this.fn=t,this.setter=n,this._value=void 0,this.dep=new go(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=zn-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=o}notify(){if(this.flags|=16,!(this.flags&8)&&Ee!==this)return jr(this,!0),!0}get value(){const t=this.dep.track();return Vr(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function $c(e,t,n=!1){let o,i;return pe(e)?o=e:(o=e.get,i=e.set),new Oc(o,i,n)}const ko={},Co=new WeakMap;let sn;function zc(e,t=!1,n=sn){if(n){let o=Co.get(n);o||Co.set(n,o=[]),o.push(e)}}function Dc(e,t,n=me){const{immediate:o,deep:i,once:r,scheduler:s,augmentJob:l,call:a}=n,u=b=>i?b:ut(b)||i===!1||i===0?Vt(b,1):Vt(b);let c,d,f,h,w=!1,y=!1;if(ze(e)?(d=()=>e.value,w=ut(e)):yn(e)?(d=()=>u(e),w=!0):re(e)?(y=!0,w=e.some(b=>yn(b)||ut(b)),d=()=>e.map(b=>{if(ze(b))return b.value;if(yn(b))return u(b);if(pe(b))return a?a(b,2):b()})):pe(e)?t?d=a?()=>a(e,2):e:d=()=>{if(f){Ct();try{f()}finally{Tt()}}const b=sn;sn=c;try{return a?a(e,3,[h]):e(h)}finally{sn=b}}:d=kt,t&&i){const b=d,g=i===!0?1/0:i;d=()=>Vt(b(),g)}const $=pi(),k=()=>{c.stop(),$&&$.active&&li($.effects,c)};if(r&&t){const b=t;t=(...g)=>{b(...g),k()}}let B=y?new Array(e.length).fill(ko):ko;const A=b=>{if(!(!(c.flags&1)||!c.dirty&&!b))if(t){const g=c.run();if(i||w||(y?g.some((E,L)=>et(E,B[L])):et(g,B))){f&&f();const E=sn;sn=c;try{const L=[g,B===ko?void 0:y&&B[0]===ko?[]:B,h];B=g,a?a(t,3,L):t(...L)}finally{sn=E}}}else c.run()};return l&&l(A),c=new Ar(d),c.scheduler=s?()=>s(A,!1):A,h=b=>zc(b,!1,c),f=c.onStop=()=>{const b=Co.get(c);if(b){if(a)a(b,4);else for(const g of b)g();Co.delete(c)}},t?o?A(!0):B=c.run():s?s(A.bind(null,!0),!0):c.run(),k.pause=c.pause.bind(c),k.resume=c.resume.bind(c),k.stop=k,k}function Vt(e,t=1/0,n){if(t<=0||!Te(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,ze(e))Vt(e.value,t,n);else if(re(e))for(let o=0;o<e.length;o++)Vt(e[o],t,n);else if(lo(e)||vn(e))e.forEach(o=>{Vt(o,t,n)});else if(ao(e)){for(const o in e)Vt(e[o],t,n);for(const o of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,o)&&Vt(e[o],t,n)}return e}/**
|
|
9
|
+
**/let qe;class hc{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=qe,!t&&qe&&(this.index=(qe.scopes||(qe.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=qe;try{return qe=this,t()}finally{qe=n}}}on(){++this._on===1&&(this.prevScope=qe,qe=this)}off(){this._on>0&&--this._on===0&&(qe=this.prevScope,this.prevScope=void 0)}stop(t){if(this._active){this._active=!1;let n,o;for(n=0,o=this.effects.length;n<o;n++)this.effects[n].stop();for(this.effects.length=0,n=0,o=this.cleanups.length;n<o;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){for(n=0,o=this.scopes.length;n<o;n++)this.scopes[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const i=this.parent.scopes.pop();i&&i!==this&&(this.parent.scopes[this.index]=i,i.index=this.index)}this.parent=void 0}}}function gi(){return qe}function gc(e,t=!1){qe&&qe.cleanups.push(e)}let Me;const mi=new WeakSet;class Rr{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,qe&&qe.active&&qe.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,mi.has(this)&&(mi.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Fr(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Zr(this),Wr(this);const t=Me,n=wt;Me=this,wt=!0;try{return this.fn()}finally{qr(this),Me=t,wt=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)wi(t);this.deps=this.depsTail=void 0,Zr(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?mi.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){yi(this)&&this.run()}get dirty(){return yi(this)}}let Hr=0,An,Bn;function Fr(e,t=!1){if(e.flags|=8,t){e.next=Bn,Bn=e;return}e.next=An,An=e}function vi(){Hr++}function bi(){if(--Hr>0)return;if(Bn){let t=Bn;for(Bn=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;An;){let t=An;for(An=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(o){e||(e=o)}t=n}}if(e)throw e}function Wr(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function qr(e){let t,n=e.depsTail,o=n;for(;o;){const i=o.prevDep;o.version===-1?(o===n&&(n=i),wi(o),mc(o)):t=o,o.dep.activeLink=o.prevActiveLink,o.prevActiveLink=void 0,o=i}e.deps=t,e.depsTail=n}function yi(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Ur(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Ur(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Ln)||(e.globalVersion=Ln,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!yi(e))))return;e.flags|=2;const t=e.dep,n=Me,o=wt;Me=e,wt=!0;try{Wr(e);const i=e.fn(e._value);(t.version===0||tt(i,e._value))&&(e.flags|=128,e._value=i,t.version++)}catch(i){throw t.version++,i}finally{Me=n,wt=o,qr(e),e.flags&=-3}}function wi(e,t=!1){const{dep:n,prevSub:o,nextSub:i}=e;if(o&&(o.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=o,e.nextSub=void 0),n.subs===e&&(n.subs=o,!o&&n.computed)){n.computed.flags&=-5;for(let r=n.computed.deps;r;r=r.nextDep)wi(r,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function mc(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let wt=!0;const Kr=[];function Tt(){Kr.push(wt),wt=!1}function Pt(){const e=Kr.pop();wt=e===void 0?!0:e}function Zr(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=Me;Me=void 0;try{t()}finally{Me=n}}}let Ln=0;class vc{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 mo{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(!Me||!wt||Me===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==Me)n=this.activeLink=new vc(Me,this),Me.deps?(n.prevDep=Me.depsTail,Me.depsTail.nextDep=n,Me.depsTail=n):Me.deps=Me.depsTail=n,Yr(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const o=n.nextDep;o.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=o),n.prevDep=Me.depsTail,n.nextDep=void 0,Me.depsTail.nextDep=n,Me.depsTail=n,Me.deps===n&&(Me.deps=o)}return n}trigger(t){this.version++,Ln++,this.notify(t)}notify(t){vi();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{bi()}}}function Yr(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let o=t.deps;o;o=o.nextDep)Yr(o)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const vo=new WeakMap,sn=Symbol(""),xi=Symbol(""),jn=Symbol("");function Ue(e,t,n){if(wt&&Me){let o=vo.get(e);o||vo.set(e,o=new Map);let i=o.get(n);i||(o.set(n,i=new mo),i.map=o,i.key=n),i.track()}}function Nt(e,t,n,o,i,r){const s=vo.get(e);if(!s){Ln++;return}const l=a=>{a&&a.trigger()};if(vi(),t==="clear")s.forEach(l);else{const a=le(e),u=a&&ui(n);if(a&&n==="length"){const c=Number(o);s.forEach((d,f)=>{(f==="length"||f===jn||!yt(f)&&f>=c)&&l(d)})}else switch((n!==void 0||s.has(void 0))&&l(s.get(n)),u&&l(s.get(jn)),t){case"add":a?u&&l(s.get("length")):(l(s.get(sn)),xn(e)&&l(s.get(xi)));break;case"delete":a||(l(s.get(sn)),xn(e)&&l(s.get(xi)));break;case"set":xn(e)&&l(s.get(sn));break}}bi()}function bc(e,t){const n=vo.get(e);return n&&n.get(t)}function _n(e){const t=_e(e);return t===e?t:(Ue(t,"iterate",jn),ut(e)?t:t.map(Ve))}function bo(e){return Ue(e=_e(e),"iterate",jn),e}const yc={__proto__:null,[Symbol.iterator](){return _i(this,Symbol.iterator,Ve)},concat(...e){return _n(this).concat(...e.map(t=>le(t)?_n(t):t))},entries(){return _i(this,"entries",e=>(e[1]=Ve(e[1]),e))},every(e,t){return Vt(this,"every",e,t,void 0,arguments)},filter(e,t){return Vt(this,"filter",e,t,n=>n.map(Ve),arguments)},find(e,t){return Vt(this,"find",e,t,Ve,arguments)},findIndex(e,t){return Vt(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return Vt(this,"findLast",e,t,Ve,arguments)},findLastIndex(e,t){return Vt(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return Vt(this,"forEach",e,t,void 0,arguments)},includes(...e){return Si(this,"includes",e)},indexOf(...e){return Si(this,"indexOf",e)},join(e){return _n(this).join(e)},lastIndexOf(...e){return Si(this,"lastIndexOf",e)},map(e,t){return Vt(this,"map",e,t,void 0,arguments)},pop(){return Nn(this,"pop")},push(...e){return Nn(this,"push",e)},reduce(e,...t){return Xr(this,"reduce",e,t)},reduceRight(e,...t){return Xr(this,"reduceRight",e,t)},shift(){return Nn(this,"shift")},some(e,t){return Vt(this,"some",e,t,void 0,arguments)},splice(...e){return Nn(this,"splice",e)},toReversed(){return _n(this).toReversed()},toSorted(e){return _n(this).toSorted(e)},toSpliced(...e){return _n(this).toSpliced(...e)},unshift(...e){return Nn(this,"unshift",e)},values(){return _i(this,"values",Ve)}};function _i(e,t,n){const o=bo(e),i=o[t]();return o!==e&&!ut(e)&&(i._next=i.next,i.next=()=>{const r=i._next();return r.done||(r.value=n(r.value)),r}),i}const wc=Array.prototype;function Vt(e,t,n,o,i,r){const s=bo(e),l=s!==e&&!ut(e),a=s[t];if(a!==wc[t]){const d=a.apply(e,r);return l?Ve(d):d}let u=n;s!==e&&(l?u=function(d,f){return n.call(this,Ve(d),f,e)}:n.length>2&&(u=function(d,f){return n.call(this,d,f,e)}));const c=a.call(s,u,o);return l&&i?i(c):c}function Xr(e,t,n,o){const i=bo(e);let r=n;return i!==e&&(ut(e)?n.length>3&&(r=function(s,l,a){return n.call(this,s,l,a,e)}):r=function(s,l,a){return n.call(this,s,Ve(l),a,e)}),i[t](r,...o)}function Si(e,t,n){const o=_e(e);Ue(o,"iterate",jn);const i=o[t](...n);return(i===-1||i===!1)&&Ci(n[0])?(n[0]=_e(n[0]),o[t](...n)):i}function Nn(e,t,n=[]){Tt(),vi();const o=_e(e)[t].apply(e,n);return bi(),Pt(),o}const xc=rt("__proto__,__v_isRef,__isVue"),Gr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(yt));function _c(e){yt(e)||(e=String(e));const t=_e(this);return Ue(t,"has",e),t.hasOwnProperty(e)}class Jr{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,o){if(n==="__v_skip")return t.__v_skip;const i=this._isReadonly,r=this._isShallow;if(n==="__v_isReactive")return!i;if(n==="__v_isReadonly")return i;if(n==="__v_isShallow")return r;if(n==="__v_raw")return o===(i?r?is:os:r?ns:ts).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(o)?t:void 0;const s=le(t);if(!i){let a;if(s&&(a=yc[n]))return a;if(n==="hasOwnProperty")return _c}const l=Reflect.get(t,n,ze(t)?t:o);if((yt(n)?Gr.has(n):xc(n))||(i||Ue(t,"get",n),r))return l;if(ze(l)){const a=s&&ui(n)?l:l.value;return i&&Ie(a)?Vn(a):a}return Ie(l)?i?Vn(l):_o(l):l}}class Qr extends Jr{constructor(t=!1){super(!1,t)}set(t,n,o,i){let r=t[n];if(!this._isShallow){const a=Yt(r);if(!ut(o)&&!Yt(o)&&(r=_e(r),o=_e(o)),!le(t)&&ze(r)&&!ze(o))return a||(r.value=o),!0}const s=le(t)&&ui(n)?Number(n)<t.length:Ce(t,n),l=Reflect.set(t,n,o,ze(t)?t:i);return t===_e(i)&&(s?tt(o,r)&&Nt(t,"set",n,o):Nt(t,"add",n,o)),l}deleteProperty(t,n){const o=Ce(t,n);t[n];const i=Reflect.deleteProperty(t,n);return i&&o&&Nt(t,"delete",n,void 0),i}has(t,n){const o=Reflect.has(t,n);return(!yt(n)||!Gr.has(n))&&Ue(t,"has",n),o}ownKeys(t){return Ue(t,"iterate",le(t)?"length":sn),Reflect.ownKeys(t)}}class es extends Jr{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const Sc=new Qr,kc=new es,Cc=new Qr(!0),Tc=new es(!0),ki=e=>e,yo=e=>Reflect.getPrototypeOf(e);function Pc(e,t,n){return function(...o){const i=this.__v_raw,r=_e(i),s=xn(r),l=e==="entries"||e===Symbol.iterator&&s,a=e==="keys"&&s,u=i[e](...o),c=n?ki:t?ko:Ve;return!t&&Ue(r,"iterate",a?xi:sn),{next(){const{value:d,done:f}=u.next();return f?{value:d,done:f}:{value:l?[c(d[0]),c(d[1])]:c(d),done:f}},[Symbol.iterator](){return this}}}}function wo(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Ic(e,t){const n={get(i){const r=this.__v_raw,s=_e(r),l=_e(i);e||(tt(i,l)&&Ue(s,"get",i),Ue(s,"get",l));const{has:a}=yo(s),u=t?ki:e?ko:Ve;if(a.call(s,i))return u(r.get(i));if(a.call(s,l))return u(r.get(l));r!==s&&r.get(i)},get size(){const i=this.__v_raw;return!e&&Ue(_e(i),"iterate",sn),i.size},has(i){const r=this.__v_raw,s=_e(r),l=_e(i);return e||(tt(i,l)&&Ue(s,"has",i),Ue(s,"has",l)),i===l?r.has(i):r.has(i)||r.has(l)},forEach(i,r){const s=this,l=s.__v_raw,a=_e(l),u=t?ki:e?ko:Ve;return!e&&Ue(a,"iterate",sn),l.forEach((c,d)=>i.call(r,u(c),u(d),s))}};return $e(n,e?{add:wo("add"),set:wo("set"),delete:wo("delete"),clear:wo("clear")}:{add(i){!t&&!ut(i)&&!Yt(i)&&(i=_e(i));const r=_e(this);return yo(r).has.call(r,i)||(r.add(i),Nt(r,"add",i,i)),this},set(i,r){!t&&!ut(r)&&!Yt(r)&&(r=_e(r));const s=_e(this),{has:l,get:a}=yo(s);let u=l.call(s,i);u||(i=_e(i),u=l.call(s,i));const c=a.call(s,i);return s.set(i,r),u?tt(r,c)&&Nt(s,"set",i,r):Nt(s,"add",i,r),this},delete(i){const r=_e(this),{has:s,get:l}=yo(r);let a=s.call(r,i);a||(i=_e(i),a=s.call(r,i)),l&&l.call(r,i);const u=r.delete(i);return a&&Nt(r,"delete",i,void 0),u},clear(){const i=_e(this),r=i.size!==0,s=i.clear();return r&&Nt(i,"clear",void 0,void 0),s}}),["keys","values","entries",Symbol.iterator].forEach(i=>{n[i]=Pc(i,e,t)}),n}function xo(e,t){const n=Ic(e,t);return(o,i,r)=>i==="__v_isReactive"?!e:i==="__v_isReadonly"?e:i==="__v_raw"?o:Reflect.get(Ce(n,i)&&i in o?n:o,i,r)}const Ec={get:xo(!1,!1)},Mc={get:xo(!1,!0)},Oc={get:xo(!0,!1)},$c={get:xo(!0,!0)},ts=new WeakMap,ns=new WeakMap,os=new WeakMap,is=new WeakMap;function Dc(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function zc(e){return e.__v_skip||!Object.isExtensible(e)?0:Dc(rc(e))}function _o(e){return Yt(e)?e:So(e,!1,Sc,Ec,ts)}function Ac(e){return So(e,!1,Cc,Mc,ns)}function Vn(e){return So(e,!0,kc,Oc,os)}function I0(e){return So(e,!0,Tc,$c,is)}function So(e,t,n,o,i){if(!Ie(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const r=zc(e);if(r===0)return e;const s=i.get(e);if(s)return s;const l=new Proxy(e,r===2?o:n);return i.set(e,l),l}function Sn(e){return Yt(e)?Sn(e.__v_raw):!!(e&&e.__v_isReactive)}function Yt(e){return!!(e&&e.__v_isReadonly)}function ut(e){return!!(e&&e.__v_isShallow)}function Ci(e){return e?!!e.__v_raw:!1}function _e(e){const t=e&&e.__v_raw;return t?_e(t):e}function Bc(e){return!Ce(e,"__v_skip")&&Object.isExtensible(e)&&Ar(e,"__v_skip",!0),e}const Ve=e=>Ie(e)?_o(e):e,ko=e=>Ie(e)?Vn(e):e;function ze(e){return e?e.__v_isRef===!0:!1}function ee(e){return rs(e,!1)}function dt(e){return rs(e,!0)}function rs(e,t){return ze(e)?e:new Lc(e,t)}class Lc{constructor(t,n){this.dep=new mo,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:_e(t),this._value=n?t:Ve(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,o=this.__v_isShallow||ut(t)||Yt(t);t=o?t:_e(t),tt(t,n)&&(this._rawValue=t,this._value=o?t:Ve(t),this.dep.trigger())}}function Z(e){return ze(e)?e.value:e}function ft(e){return he(e)?e():Z(e)}const jc={get:(e,t,n)=>t==="__v_raw"?e:Z(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const i=e[t];return ze(i)&&!ze(n)?(i.value=n,!0):Reflect.set(e,t,n,o)}};function ss(e){return Sn(e)?e:new Proxy(e,jc)}class Nc{constructor(t){this.__v_isRef=!0,this._value=void 0;const n=this.dep=new mo,{get:o,set:i}=t(n.track.bind(n),n.trigger.bind(n));this._get=o,this._set=i}get value(){return this._value=this._get()}set value(t){this._set(t)}}function ls(e){return new Nc(e)}class Vc{constructor(t,n,o){this._object=t,this._key=n,this._defaultValue=o,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 bc(_e(this._object),this._key)}}class Rc{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function Hc(e,t,n){return ze(e)?e:he(e)?new Rc(e):Ie(e)&&arguments.length>1?Fc(e,t,n):ee(e)}function Fc(e,t,n){const o=e[t];return ze(o)?o:new Vc(e,t,n)}class Wc{constructor(t,n,o){this.fn=t,this.setter=n,this._value=void 0,this.dep=new mo(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Ln-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=o}notify(){if(this.flags|=16,!(this.flags&8)&&Me!==this)return Fr(this,!0),!0}get value(){const t=this.dep.track();return Ur(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function qc(e,t,n=!1){let o,i;return he(e)?o=e:(o=e.get,i=e.set),new Wc(o,i,n)}const Co={},To=new WeakMap;let ln;function Uc(e,t=!1,n=ln){if(n){let o=To.get(n);o||To.set(n,o=[]),o.push(e)}}function Kc(e,t,n=me){const{immediate:o,deep:i,once:r,scheduler:s,augmentJob:l,call:a}=n,u=C=>i?C:ut(C)||i===!1||i===0?Rt(C,1):Rt(C);let c,d,f,p,b=!1,y=!1;if(ze(e)?(d=()=>e.value,b=ut(e)):Sn(e)?(d=()=>u(e),b=!0):le(e)?(y=!0,b=e.some(C=>Sn(C)||ut(C)),d=()=>e.map(C=>{if(ze(C))return C.value;if(Sn(C))return u(C);if(he(C))return a?a(C,2):C()})):he(e)?t?d=a?()=>a(e,2):e:d=()=>{if(f){Tt();try{f()}finally{Pt()}}const C=ln;ln=c;try{return a?a(e,3,[p]):e(p)}finally{ln=C}}:d=Ct,t&&i){const C=d,g=i===!0?1/0:i;d=()=>Rt(C(),g)}const $=gi(),k=()=>{c.stop(),$&&$.active&&ci($.effects,c)};if(r&&t){const C=t;t=(...g)=>{C(...g),k()}}let B=y?new Array(e.length).fill(Co):Co;const F=C=>{if(!(!(c.flags&1)||!c.dirty&&!C))if(t){const g=c.run();if(i||b||(y?g.some((T,x)=>tt(T,B[x])):tt(g,B))){f&&f();const T=ln;ln=c;try{const x=[g,B===Co?void 0:y&&B[0]===Co?[]:B,p];B=g,a?a(t,3,x):t(...x)}finally{ln=T}}}else c.run()};return l&&l(F),c=new Rr(d),c.scheduler=s?()=>s(F,!1):F,p=C=>Uc(C,!1,c),f=c.onStop=()=>{const C=To.get(c);if(C){if(a)a(C,4);else for(const g of C)g();To.delete(c)}},t?o?F(!0):B=c.run():s?s(F.bind(null,!0),!0):c.run(),k.pause=c.pause.bind(c),k.resume=c.resume.bind(c),k.stop=k,k}function Rt(e,t=1/0,n){if(t<=0||!Ie(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,ze(e))Rt(e.value,t,n);else if(le(e))for(let o=0;o<e.length;o++)Rt(e[o],t,n);else if(ao(e)||xn(e))e.forEach(o=>{Rt(o,t,n)});else if(co(e)){for(const o in e)Rt(e[o],t,n);for(const o of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,o)&&Rt(e[o],t,n)}return e}/**
|
|
10
10
|
* @vue/runtime-core v3.5.24
|
|
11
11
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
12
12
|
* @license MIT
|
|
13
|
-
**/const
|
|
13
|
+
**/const Rn=[];let Ti=!1;function E0(e,...t){if(Ti)return;Ti=!0,Tt();const n=Rn.length?Rn[Rn.length-1].component:null,o=n&&n.appContext.config.warnHandler,i=Zc();if(o)kn(o,n,11,[e+t.map(r=>{var s,l;return(l=(s=r.toString)==null?void 0:s.call(r))!=null?l:JSON.stringify(r)}).join(""),n&&n.proxy,i.map(({vnode:r})=>`at <${cl(n,r.type)}>`).join(`
|
|
14
14
|
`),i]);else{const r=[`[Vue warn]: ${e}`,...t];i.length&&r.push(`
|
|
15
|
-
`,...
|
|
16
|
-
`],...jc(n))}),t}function jc({vnode:e,recurseCount:t}){const n=t>0?`... (${t} recursive calls)`:"",o=e.component?e.component.parent==null:!1,i=` at <${ol(e.component,e.type,o)}`,r=">"+n;return e.props?[i,...Bc(e.props),r]:[i+r]}function Bc(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach(o=>{t.push(...ns(o,e[o]))}),n.length>3&&t.push(" ..."),t}function ns(e,t,n){return $e(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):typeof t=="number"||typeof t=="boolean"||t==null?n?t:[`${e}=${t}`]:ze(t)?(t=ns(e,xe(t.value),!0),n?t:[`${e}=Ref<`,t,">"]):pe(t)?[`${e}=fn${t.name?`<${t.name}>`:""}`]:(t=xe(t),n?t:[`${e}=`,t])}function wn(e,t,n,o){try{return o?e(...o):e()}catch(i){To(i,t,n)}}function wt(e,t,n,o){if(pe(e)){const i=wn(e,t,n,o);return i&&Mr(i)&&i.catch(r=>{To(r,t,n)}),i}if(re(e)){const i=[];for(let r=0;r<e.length;r++)i.push(wt(e[r],t,n,o));return i}}function To(e,t,n,o=!0){const i=t?t.vnode:null,{errorHandler:r,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||me;if(t){let l=t.parent;const a=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${n}`;for(;l;){const c=l.ec;if(c){for(let d=0;d<c.length;d++)if(c[d](e,a,u)===!1)return}l=l.parent}if(r){Ct(),wn(r,null,10,[e,a,u]),Tt();return}}Nc(e,n,i,o,s)}function Nc(e,t,n,o=!0,i=!1){if(i)throw e;console.error(e)}const Ze=[];let Mt=-1;const xn=[];let Yt=null,_n=0;const os=Promise.resolve();let Mo=null;function pt(e){const t=Mo||os;return e?t.then(this?e.bind(this):e):t}function Vc(e){let t=Mt+1,n=Ze.length;for(;t<n;){const o=t+n>>>1,i=Ze[o],r=Bn(i);r<e||r===e&&i.flags&2?t=o+1:n=o}return t}function Ci(e){if(!(e.flags&1)){const t=Bn(e),n=Ze[Ze.length-1];!n||!(e.flags&2)&&t>=Bn(n)?Ze.push(e):Ze.splice(Vc(t),0,e),e.flags|=1,is()}}function is(){Mo||(Mo=os.then(ls))}function Rc(e){re(e)?xn.push(...e):Yt&&e.id===-1?Yt.splice(_n+1,0,e):e.flags&1||(xn.push(e),e.flags|=1),is()}function rs(e,t,n=Mt+1){for(;n<Ze.length;n++){const o=Ze[n];if(o&&o.flags&2){if(e&&o.id!==e.uid)continue;Ze.splice(n,1),n--,o.flags&4&&(o.flags&=-2),o(),o.flags&4||(o.flags&=-2)}}}function ss(e){if(xn.length){const t=[...new Set(xn)].sort((n,o)=>Bn(n)-Bn(o));if(xn.length=0,Yt){Yt.push(...t);return}for(Yt=t,_n=0;_n<Yt.length;_n++){const n=Yt[_n];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}Yt=null,_n=0}}const Bn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function ls(e){try{for(Mt=0;Mt<Ze.length;Mt++){const t=Ze[Mt];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),wn(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Mt<Ze.length;Mt++){const t=Ze[Mt];t&&(t.flags&=-2)}Mt=-1,Ze.length=0,ss(),Mo=null,(Ze.length||xn.length)&&ls()}}let Ve=null,as=null;function Po(e){const t=Ve;return Ve=e,as=e&&e.type.__scopeId||null,t}function oe(e,t=Ve,n){if(!t||e._n)return e;const o=(...i)=>{o._d&&No(-1);const r=Po(t);let s;try{s=e(...i)}finally{Po(r),o._d&&No(1)}return s};return o._n=!0,o._c=!0,o._d=!0,o}function Re(e,t){if(Ve===null)return e;const n=Ho(Ve),o=e.dirs||(e.dirs=[]);for(let i=0;i<t.length;i++){let[r,s,l,a=me]=t[i];r&&(pe(r)&&(r={mounted:r,updated:r}),r.deep&&Vt(s),o.push({dir:r,instance:n,value:s,oldValue:void 0,arg:l,modifiers:a}))}return e}function ln(e,t,n,o){const i=e.dirs,r=t&&t.dirs;for(let s=0;s<i.length;s++){const l=i[s];r&&(l.oldValue=r[s].value);let a=l.dir[o];a&&(Ct(),wt(a,n,8,[e.el,l,e,t]),Tt())}}const Hc=Symbol("_vte"),cs=e=>e.__isTeleport,Rt=Symbol("_leaveCb"),Eo=Symbol("_enterCb");function Fc(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return je(()=>{e.isMounted=!0}),Pi(()=>{e.isUnmounting=!0}),e}const ht=[Function,Array],us={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:ht,onEnter:ht,onAfterEnter:ht,onEnterCancelled:ht,onBeforeLeave:ht,onLeave:ht,onAfterLeave:ht,onLeaveCancelled:ht,onBeforeAppear:ht,onAppear:ht,onAfterAppear:ht,onAppearCancelled:ht},ds=e=>{const t=e.subTree;return t.component?ds(t.component):t},Wc={name:"BaseTransition",props:us,setup(e,{slots:t}){const n=dn(),o=Fc();return()=>{const i=t.default&&gs(t.default(),!0);if(!i||!i.length)return;const r=fs(i),s=xe(e),{mode:l}=s;if(o.isLeaving)return Mi(r);const a=hs(r);if(!a)return Mi(r);let u=Ti(a,s,o,n,d=>u=d);a.type!==qe&&Nn(a,u);let c=n.subTree&&hs(n.subTree);if(c&&c.type!==qe&&!un(c,a)&&ds(n).type!==qe){let d=Ti(c,s,o,n);if(Nn(c,d),l==="out-in"&&a.type!==qe)return o.isLeaving=!0,d.afterLeave=()=>{o.isLeaving=!1,n.job.flags&8||n.update(),delete d.afterLeave,c=void 0},Mi(r);l==="in-out"&&a.type!==qe?d.delayLeave=(f,h,w)=>{const y=ps(o,c);y[String(c.key)]=c,f[Rt]=()=>{h(),f[Rt]=void 0,delete u.delayedLeave,c=void 0},u.delayedLeave=()=>{w(),delete u.delayedLeave,c=void 0}}:c=void 0}else c&&(c=void 0);return r}}};function fs(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==qe){t=n;break}}return t}const Uc=Wc;function ps(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function Ti(e,t,n,o,i){const{appear:r,mode:s,persisted:l=!1,onBeforeEnter:a,onEnter:u,onAfterEnter:c,onEnterCancelled:d,onBeforeLeave:f,onLeave:h,onAfterLeave:w,onLeaveCancelled:y,onBeforeAppear:$,onAppear:k,onAfterAppear:B,onAppearCancelled:A}=t,b=String(e.key),g=ps(n,e),E=(_,O)=>{_&&wt(_,o,9,O)},L=(_,O)=>{const j=O[1];E(_,O),re(_)?_.every(M=>M.length<=1)&&j():_.length<=1&&j()},Z={mode:s,persisted:l,beforeEnter(_){let O=a;if(!n.isMounted)if(r)O=$||a;else return;_[Rt]&&_[Rt](!0);const j=g[b];j&&un(e,j)&&j.el[Rt]&&j.el[Rt](),E(O,[_])},enter(_){let O=u,j=c,M=d;if(!n.isMounted)if(r)O=k||u,j=B||c,M=A||d;else return;let G=!1;const C=_[Eo]=ee=>{G||(G=!0,ee?E(M,[_]):E(j,[_]),Z.delayedLeave&&Z.delayedLeave(),_[Eo]=void 0)};O?L(O,[_,C]):C()},leave(_,O){const j=String(e.key);if(_[Eo]&&_[Eo](!0),n.isUnmounting)return O();E(f,[_]);let M=!1;const G=_[Rt]=C=>{M||(M=!0,O(),C?E(y,[_]):E(w,[_]),_[Rt]=void 0,g[j]===e&&delete g[j])};g[j]=e,h?L(h,[_,G]):G()},clone(_){const O=Ti(_,t,n,o,i);return i&&i(O),O}};return Z}function Mi(e){if(Oo(e))return e=Gt(e),e.children=null,e}function hs(e){if(!Oo(e))return cs(e.type)&&e.children?fs(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&&pe(n.default))return n.default()}}function Nn(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Nn(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 gs(e,t=!1,n){let o=[],i=0;for(let r=0;r<e.length;r++){let s=e[r];const l=n==null?s.key:String(n)+String(s.key!=null?s.key:r);s.type===ye?(s.patchFlag&128&&i++,o=o.concat(gs(s.children,t,l))):(t||s.type!==qe)&&o.push(l!=null?Gt(s,{key:l}):s)}if(i>1)for(let r=0;r<o.length;r++)o[r].patchFlag=-2;return o}function ge(e,t){return pe(e)?Oe({name:e.name},t,{setup:e}):e}function ms(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}const Io=new WeakMap;function Vn(e,t,n,o,i=!1){if(re(e)){e.forEach((w,y)=>Vn(w,t&&(re(t)?t[y]:t),n,o,i));return}if(Sn(o)&&!i){o.shapeFlag&512&&o.type.__asyncResolved&&o.component.subTree.component&&Vn(e,t,n,o.component.subTree);return}const r=o.shapeFlag&4?Ho(o.component):o.el,s=i?null:r,{i:l,r:a}=e,u=t&&t.r,c=l.refs===me?l.refs={}:l.refs,d=l.setupState,f=xe(d),h=d===me?Cr:w=>ke(f,w);if(u!=null&&u!==a){if(vs(t),$e(u))c[u]=null,h(u)&&(d[u]=null);else if(ze(u)){u.value=null;const w=t;w.k&&(c[w.k]=null)}}if(pe(a))wn(a,l,12,[s,c]);else{const w=$e(a),y=ze(a);if(w||y){const $=()=>{if(e.f){const k=w?h(a)?d[a]:c[a]:a.value;if(i)re(k)&&li(k,r);else if(re(k))k.includes(r)||k.push(r);else if(w)c[a]=[r],h(a)&&(d[a]=c[a]);else{const B=[r];a.value=B,e.k&&(c[e.k]=B)}}else w?(c[a]=s,h(a)&&(d[a]=s)):y&&(a.value=s,e.k&&(c[e.k]=s))};if(s){const k=()=>{$(),Io.delete(e)};k.id=-1,Io.set(e,k),rt(k,n)}else vs(e),$()}}}function vs(e){const t=Io.get(e);t&&(t.flags|=8,Io.delete(e))}po().requestIdleCallback,po().cancelIdleCallback;const Sn=e=>!!e.type.__asyncLoader,Oo=e=>e.type.__isKeepAlive;function qc(e,t){bs(e,"a",t)}function Kc(e,t){bs(e,"da",t)}function bs(e,t,n=Ke){const o=e.__wdc||(e.__wdc=()=>{let i=n;for(;i;){if(i.isDeactivated)return;i=i.parent}return e()});if($o(t,o,n),n){let i=n.parent;for(;i&&i.parent;)Oo(i.parent.vnode)&&Zc(o,t,n,i),i=i.parent}}function Zc(e,t,n,o){const i=$o(t,e,o,!0);Pt(()=>{li(o[t],i)},n)}function $o(e,t,n=Ke,o=!1){if(n){const i=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...s)=>{Ct();const l=Kn(n),a=wt(t,n,e,s);return l(),Tt(),a});return o?i.unshift(r):i.push(r),r}}const Ht=e=>(t,n=Ke)=>{(!Zn||e==="sp")&&$o(e,(...o)=>t(...o),n)},Yc=Ht("bm"),je=Ht("m"),Xc=Ht("bu"),Gc=Ht("u"),Pi=Ht("bum"),Pt=Ht("um"),Jc=Ht("sp"),Qc=Ht("rtg"),eu=Ht("rtc");function ys(e,t=Ke){$o("ec",e,t)}const tu="components",ws=Symbol.for("v-ndc");function xs(e){return $e(e)?nu(tu,e,!1)||e:e||ws}function nu(e,t,n=!0,o=!1){const i=Ve||Ke;if(i){const r=i.type;{const l=nl(r,!1);if(l&&(l===t||l===He(t)||l===uo(He(t))))return r}const s=_s(i[e]||r[e],t)||_s(i.appContext[e],t);return!s&&o?r:s}}function _s(e,t){return e&&(e[t]||e[He(t)]||e[uo(He(t))])}function Xt(e,t,n,o){let i;const r=n,s=re(e);if(s||$e(e)){const l=s&&yn(e);let a=!1,u=!1;l&&(a=!ut(e),u=Zt(e),e=vo(e)),i=new Array(e.length);for(let c=0,d=e.length;c<d;c++)i[c]=t(a?u?So(Ne(e[c])):Ne(e[c]):e[c],c,void 0,r)}else if(typeof e=="number"){i=new Array(e);for(let l=0;l<e;l++)i[l]=t(l+1,l,void 0,r)}else if(Te(e))if(e[Symbol.iterator])i=Array.from(e,(l,a)=>t(l,a,void 0,r));else{const l=Object.keys(e);i=new Array(l.length);for(let a=0,u=l.length;a<u;a++){const c=l[a];i[a]=t(e[c],c,a,r)}}else i=[];return i}function Ei(e,t){for(let n=0;n<t.length;n++){const o=t[n];if(re(o))for(let i=0;i<o.length;i++)e[o[i].name]=o[i].fn;else o&&(e[o.name]=o.key?(...i)=>{const r=o.fn(...i);return r&&(r.key=o.key),r}:o.fn)}return e}function Se(e,t,n={},o,i){if(Ve.ce||Ve.parent&&Sn(Ve.parent)&&Ve.parent.ce){const u=Object.keys(n).length>0;return t!=="default"&&(n.name=t),v(),ie(ye,null,[V("slot",n,o&&o())],u?-2:64)}let r=e[t];r&&r._c&&(r._d=!1),v();const s=r&&Ss(r(n)),l=n.key||s&&s.key,a=ie(ye,{key:(l&&!bt(l)?l:`_${t}`)+(!s&&o?"_fb":"")},s||(o?o():[]),s&&e._===1?64:-2);return a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),r&&r._c&&(r._d=!0),a}function Ss(e){return e.some(t=>qn(t)?!(t.type===qe||t.type===ye&&!Ss(t.children)):!0)?e:null}const Ii=e=>e?Qs(e)?Ho(e):Ii(e.parent):null,Rn=Oe(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=>Ii(e.parent),$root:e=>Ii(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Ts(e),$forceUpdate:e=>e.f||(e.f=()=>{Ci(e.update)}),$nextTick:e=>e.n||(e.n=pt.bind(e.proxy)),$watch:e=>ku.bind(e)}),Oi=(e,t)=>e!==me&&!e.__isScriptSetup&&ke(e,t),ou={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:o,data:i,props:r,accessCache:s,type:l,appContext:a}=e;let u;if(t[0]!=="$"){const h=s[t];if(h!==void 0)switch(h){case 1:return o[t];case 2:return i[t];case 4:return n[t];case 3:return r[t]}else{if(Oi(o,t))return s[t]=1,o[t];if(i!==me&&ke(i,t))return s[t]=2,i[t];if((u=e.propsOptions[0])&&ke(u,t))return s[t]=3,r[t];if(n!==me&&ke(n,t))return s[t]=4,n[t];$i&&(s[t]=0)}}const c=Rn[t];let d,f;if(c)return t==="$attrs"&&Ue(e.attrs,"get",""),c(e);if((d=l.__cssModules)&&(d=d[t]))return d;if(n!==me&&ke(n,t))return s[t]=4,n[t];if(f=a.config.globalProperties,ke(f,t))return f[t]},set({_:e},t,n){const{data:o,setupState:i,ctx:r}=e;return Oi(i,t)?(i[t]=n,!0):o!==me&&ke(o,t)?(o[t]=n,!0):ke(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:i,propsOptions:r,type:s}},l){let a,u;return!!(n[l]||e!==me&&l[0]!=="$"&&ke(e,l)||Oi(t,l)||(a=r[0])&&ke(a,l)||ke(o,l)||ke(Rn,l)||ke(i.config.globalProperties,l)||(u=s.__cssModules)&&u[l])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:ke(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function zo(e){return re(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function Ye(e,t){return!e||!t?e||t:re(e)&&re(t)?e.concat(t):Oe({},zo(e),zo(t))}let $i=!0;function iu(e){const t=Ts(e),n=e.proxy,o=e.ctx;$i=!1,t.beforeCreate&&ks(t.beforeCreate,e,"bc");const{data:i,computed:r,methods:s,watch:l,provide:a,inject:u,created:c,beforeMount:d,mounted:f,beforeUpdate:h,updated:w,activated:y,deactivated:$,beforeDestroy:k,beforeUnmount:B,destroyed:A,unmounted:b,render:g,renderTracked:E,renderTriggered:L,errorCaptured:Z,serverPrefetch:_,expose:O,inheritAttrs:j,components:M,directives:G,filters:C}=t;if(u&&ru(u,o,null),s)for(const S in s){const x=s[S];pe(x)&&(o[S]=x.bind(n))}if(i){const S=i.call(n,n);Te(S)&&(e.data=xo(S))}if($i=!0,r)for(const S in r){const x=r[S],U=pe(x)?x.bind(n,n):pe(x.get)?x.get.bind(n,n):kt,K=!pe(x)&&pe(x.set)?x.set.bind(n):kt,D=Q({get:U,set:K});Object.defineProperty(o,S,{enumerable:!0,configurable:!0,get:()=>D.value,set:fe=>D.value=fe})}if(l)for(const S in l)Cs(l[S],o,n,S);if(a){const S=pe(a)?a.call(n):a;Reflect.ownKeys(S).forEach(x=>{Fn(x,S[x])})}c&&ks(c,e,"c");function W(S,x){re(x)?x.forEach(U=>S(U.bind(n))):x&&S(x.bind(n))}if(W(Yc,d),W(je,f),W(Xc,h),W(Gc,w),W(qc,y),W(Kc,$),W(ys,Z),W(eu,E),W(Qc,L),W(Pi,B),W(Pt,b),W(Jc,_),re(O))if(O.length){const S=e.exposed||(e.exposed={});O.forEach(x=>{Object.defineProperty(S,x,{get:()=>n[x],set:U=>n[x]=U,enumerable:!0})})}else e.exposed||(e.exposed={});g&&e.render===kt&&(e.render=g),j!=null&&(e.inheritAttrs=j),M&&(e.components=M),G&&(e.directives=G),_&&ms(e)}function ru(e,t,n=kt){re(e)&&(e=zi(e));for(const o in e){const i=e[o];let r;Te(i)?"default"in i?r=Ft(i.from||o,i.default,!0):r=Ft(i.from||o):r=Ft(i),ze(r)?Object.defineProperty(t,o,{enumerable:!0,configurable:!0,get:()=>r.value,set:s=>r.value=s}):t[o]=r}}function ks(e,t,n){wt(re(e)?e.map(o=>o.bind(t.proxy)):e.bind(t.proxy),t,n)}function Cs(e,t,n,o){let i=o.includes(".")?Ws(n,o):()=>n[o];if($e(e)){const r=t[e];pe(r)&&de(i,r)}else if(pe(e))de(i,e.bind(n));else if(Te(e))if(re(e))e.forEach(r=>Cs(r,t,n,o));else{const r=pe(e.handler)?e.handler.bind(n):t[e.handler];pe(r)&&de(i,r,e)}}function Ts(e){const t=e.type,{mixins:n,extends:o}=t,{mixins:i,optionsCache:r,config:{optionMergeStrategies:s}}=e.appContext,l=r.get(t);let a;return l?a=l:!i.length&&!n&&!o?a=t:(a={},i.length&&i.forEach(u=>Do(a,u,s,!0)),Do(a,t,s)),Te(t)&&r.set(t,a),a}function Do(e,t,n,o=!1){const{mixins:i,extends:r}=t;r&&Do(e,r,n,!0),i&&i.forEach(s=>Do(e,s,n,!0));for(const s in t)if(!(o&&s==="expose")){const l=su[s]||n&&n[s];e[s]=l?l(e[s],t[s]):t[s]}return e}const su={data:Ms,props:Ps,emits:Ps,methods:Hn,computed:Hn,beforeCreate:Xe,created:Xe,beforeMount:Xe,mounted:Xe,beforeUpdate:Xe,updated:Xe,beforeDestroy:Xe,beforeUnmount:Xe,destroyed:Xe,unmounted:Xe,activated:Xe,deactivated:Xe,errorCaptured:Xe,serverPrefetch:Xe,components:Hn,directives:Hn,watch:au,provide:Ms,inject:lu};function Ms(e,t){return t?e?function(){return Oe(pe(e)?e.call(this,this):e,pe(t)?t.call(this,this):t)}:t:e}function lu(e,t){return Hn(zi(e),zi(t))}function zi(e){if(re(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Xe(e,t){return e?[...new Set([].concat(e,t))]:t}function Hn(e,t){return e?Oe(Object.create(null),e,t):t}function Ps(e,t){return e?re(e)&&re(t)?[...new Set([...e,...t])]:Oe(Object.create(null),zo(e),zo(t??{})):t}function au(e,t){if(!e)return t;if(!t)return e;const n=Oe(Object.create(null),e);for(const o in t)n[o]=Xe(e[o],t[o]);return n}function Es(){return{app:null,config:{isNativeTag:Cr,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 cu=0;function uu(e,t){return function(o,i=null){pe(o)||(o=Oe({},o)),i!=null&&!Te(i)&&(i=null);const r=Es(),s=new WeakSet,l=[];let a=!1;const u=r.app={_uid:cu++,_component:o,_props:i,_container:null,_context:r,_instance:null,version:qu,get config(){return r.config},set config(c){},use(c,...d){return s.has(c)||(c&&pe(c.install)?(s.add(c),c.install(u,...d)):pe(c)&&(s.add(c),c(u,...d))),u},mixin(c){return r.mixins.includes(c)||r.mixins.push(c),u},component(c,d){return d?(r.components[c]=d,u):r.components[c]},directive(c,d){return d?(r.directives[c]=d,u):r.directives[c]},mount(c,d,f){if(!a){const h=u._ceVNode||V(o,i);return h.appContext=r,f===!0?f="svg":f===!1&&(f=void 0),e(h,c,f),a=!0,u._container=c,c.__vue_app__=u,Ho(h.component)}},onUnmount(c){l.push(c)},unmount(){a&&(wt(l,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(c,d){return r.provides[c]=d,u},runWithContext(c){const d=an;an=u;try{return c()}finally{an=d}}};return u}}let an=null;function Fn(e,t){if(Ke){let n=Ke.provides;const o=Ke.parent&&Ke.parent.provides;o===n&&(n=Ke.provides=Object.create(o)),n[e]=t}}function Ft(e,t,n=!1){const o=dn();if(o||an){let i=an?an._context.provides:o?o.parent==null||o.ce?o.vnode.appContext&&o.vnode.appContext.provides:o.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&pe(t)?t.call(o&&o.proxy):t}}function Is(){return!!(dn()||an)}const Os={},$s=()=>Object.create(Os),zs=e=>Object.getPrototypeOf(e)===Os;function du(e,t,n,o=!1){const i={},r=$s();e.propsDefaults=Object.create(null),Ds(e,t,i,r);for(const s in e.propsOptions[0])s in i||(i[s]=void 0);n?e.props=o?i:_c(i):e.type.props?e.props=i:e.props=r,e.attrs=r}function fu(e,t,n,o){const{props:i,attrs:r,vnode:{patchFlag:s}}=e,l=xe(i),[a]=e.propsOptions;let u=!1;if((o||s>0)&&!(s&16)){if(s&8){const c=e.vnode.dynamicProps;for(let d=0;d<c.length;d++){let f=c[d];if(Lo(e.emitsOptions,f))continue;const h=t[f];if(a)if(ke(r,f))h!==r[f]&&(r[f]=h,u=!0);else{const w=He(f);i[w]=Di(a,l,w,h,e,!1)}else h!==r[f]&&(r[f]=h,u=!0)}}}else{Ds(e,t,i,r)&&(u=!0);let c;for(const d in l)(!t||!ke(t,d)&&((c=Qe(d))===d||!ke(t,c)))&&(a?n&&(n[d]!==void 0||n[c]!==void 0)&&(i[d]=Di(a,l,d,void 0,e,!0)):delete i[d]);if(r!==l)for(const d in r)(!t||!ke(t,d))&&(delete r[d],u=!0)}u&&Bt(e.attrs,"set","")}function Ds(e,t,n,o){const[i,r]=e.propsOptions;let s=!1,l;if(t)for(let a in t){if(In(a))continue;const u=t[a];let c;i&&ke(i,c=He(a))?!r||!r.includes(c)?n[c]=u:(l||(l={}))[c]=u:Lo(e.emitsOptions,a)||(!(a in o)||u!==o[a])&&(o[a]=u,s=!0)}if(r){const a=xe(n),u=l||me;for(let c=0;c<r.length;c++){const d=r[c];n[d]=Di(i,a,d,u[d],e,!ke(u,d))}}return s}function Di(e,t,n,o,i,r){const s=e[n];if(s!=null){const l=ke(s,"default");if(l&&o===void 0){const a=s.default;if(s.type!==Function&&!s.skipFactory&&pe(a)){const{propsDefaults:u}=i;if(n in u)o=u[n];else{const c=Kn(i);o=u[n]=a.call(null,t),c()}}else o=a;i.ce&&i.ce._setProp(n,o)}s[0]&&(r&&!l?o=!1:s[1]&&(o===""||o===Qe(n))&&(o=!0))}return o}const pu=new WeakMap;function As(e,t,n=!1){const o=n?pu:t.propsCache,i=o.get(e);if(i)return i;const r=e.props,s={},l=[];let a=!1;if(!pe(e)){const c=d=>{a=!0;const[f,h]=As(d,t,!0);Oe(s,f),h&&l.push(...h)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!a)return Te(e)&&o.set(e,vt),vt;if(re(r))for(let c=0;c<r.length;c++){const d=He(r[c]);Ls(d)&&(s[d]=me)}else if(r)for(const c in r){const d=He(c);if(Ls(d)){const f=r[c],h=s[d]=re(f)||pe(f)?{type:f}:Oe({},f),w=h.type;let y=!1,$=!0;if(re(w))for(let k=0;k<w.length;++k){const B=w[k],A=pe(B)&&B.name;if(A==="Boolean"){y=!0;break}else A==="String"&&($=!1)}else y=pe(w)&&w.name==="Boolean";h[0]=y,h[1]=$,(y||ke(h,"default"))&&l.push(d)}}const u=[s,l];return Te(e)&&o.set(e,u),u}function Ls(e){return e[0]!=="$"&&!In(e)}const Ai=e=>e==="_"||e==="_ctx"||e==="$stable",Li=e=>re(e)?e.map(Et):[Et(e)],hu=(e,t,n)=>{if(t._n)return t;const o=oe((...i)=>Li(t(...i)),n);return o._c=!1,o},js=(e,t,n)=>{const o=e._ctx;for(const i in e){if(Ai(i))continue;const r=e[i];if(pe(r))t[i]=hu(i,r,o);else if(r!=null){const s=Li(r);t[i]=()=>s}}},Bs=(e,t)=>{const n=Li(t);e.slots.default=()=>n},Ns=(e,t,n)=>{for(const o in t)(n||!Ai(o))&&(e[o]=t[o])},gu=(e,t,n)=>{const o=e.slots=$s();if(e.vnode.shapeFlag&32){const i=t._;i?(Ns(o,t,n),n&&Er(o,"_",i,!0)):js(t,o)}else t&&Bs(e,t)},mu=(e,t,n)=>{const{vnode:o,slots:i}=e;let r=!0,s=me;if(o.shapeFlag&32){const l=t._;l?n&&l===1?r=!1:Ns(i,t,n):(r=!t.$stable,js(t,i)),s=t}else t&&(Bs(e,t),s={default:1});if(r)for(const l in i)!Ai(l)&&s[l]==null&&delete i[l]},rt=Ou;function vu(e){return bu(e)}function bu(e,t){const n=po();n.__VUE__=!0;const{insert:o,remove:i,patchProp:r,createElement:s,createText:l,createComment:a,setText:u,setElementText:c,parentNode:d,nextSibling:f,setScopeId:h=kt,insertStaticContent:w}=e,y=(p,m,P,q=null,R=null,F=null,I=void 0,T=null,H=!!m.dynamicChildren)=>{if(p===m)return;p&&!un(p,m)&&(q=Ae(p),fe(p,R,F,!0),p=null),m.patchFlag===-2&&(H=!1,m.dynamicChildren=null);const{type:N,ref:se,shapeFlag:ne}=m;switch(N){case jo:$(p,m,P,q);break;case qe:k(p,m,P,q);break;case Bo:p==null&&B(m,P,q,I);break;case ye:M(p,m,P,q,R,F,I,T,H);break;default:ne&1?g(p,m,P,q,R,F,I,T,H):ne&6?G(p,m,P,q,R,F,I,T,H):(ne&64||ne&128)&&N.process(p,m,P,q,R,F,I,T,H,De)}se!=null&&R?Vn(se,p&&p.ref,F,m||p,!m):se==null&&p&&p.ref!=null&&Vn(p.ref,null,F,p,!0)},$=(p,m,P,q)=>{if(p==null)o(m.el=l(m.children),P,q);else{const R=m.el=p.el;m.children!==p.children&&u(R,m.children)}},k=(p,m,P,q)=>{p==null?o(m.el=a(m.children||""),P,q):m.el=p.el},B=(p,m,P,q)=>{[p.el,p.anchor]=w(p.children,m,P,q,p.el,p.anchor)},A=({el:p,anchor:m},P,q)=>{let R;for(;p&&p!==m;)R=f(p),o(p,P,q),p=R;o(m,P,q)},b=({el:p,anchor:m})=>{let P;for(;p&&p!==m;)P=f(p),i(p),p=P;i(m)},g=(p,m,P,q,R,F,I,T,H)=>{if(m.type==="svg"?I="svg":m.type==="math"&&(I="mathml"),p==null)E(m,P,q,R,F,I,T,H);else{const N=p.el&&p.el._isVueCE?p.el:null;try{N&&N._beginPatch(),_(p,m,R,F,I,T,H)}finally{N&&N._endPatch()}}},E=(p,m,P,q,R,F,I,T)=>{let H,N;const{props:se,shapeFlag:ne,transition:J,dirs:ce}=p;if(H=p.el=s(p.type,F,se&&se.is,se),ne&8?c(H,p.children):ne&16&&Z(p.children,H,null,q,R,ji(p,F),I,T),ce&&ln(p,null,q,"created"),L(H,p,p.scopeId,I,q),se){for(const Ie in se)Ie!=="value"&&!In(Ie)&&r(H,Ie,null,se[Ie],F,q);"value"in se&&r(H,"value",null,se.value,F),(N=se.onVnodeBeforeMount)&&It(N,q,p)}ce&&ln(p,null,q,"beforeMount");const _e=yu(R,J);_e&&J.beforeEnter(H),o(H,m,P),((N=se&&se.onVnodeMounted)||_e||ce)&&rt(()=>{N&&It(N,q,p),_e&&J.enter(H),ce&&ln(p,null,q,"mounted")},R)},L=(p,m,P,q,R)=>{if(P&&h(p,P),q)for(let F=0;F<q.length;F++)h(p,q[F]);if(R){let F=R.subTree;if(m===F||Ys(F.type)&&(F.ssContent===m||F.ssFallback===m)){const I=R.vnode;L(p,I,I.scopeId,I.slotScopeIds,R.parent)}}},Z=(p,m,P,q,R,F,I,T,H=0)=>{for(let N=H;N<p.length;N++){const se=p[N]=T?Jt(p[N]):Et(p[N]);y(null,se,m,P,q,R,F,I,T)}},_=(p,m,P,q,R,F,I)=>{const T=m.el=p.el;let{patchFlag:H,dynamicChildren:N,dirs:se}=m;H|=p.patchFlag&16;const ne=p.props||me,J=m.props||me;let ce;if(P&&cn(P,!1),(ce=J.onVnodeBeforeUpdate)&&It(ce,P,m,p),se&&ln(m,p,P,"beforeUpdate"),P&&cn(P,!0),(ne.innerHTML&&J.innerHTML==null||ne.textContent&&J.textContent==null)&&c(T,""),N?O(p.dynamicChildren,N,T,P,q,ji(m,R),F):I||x(p,m,T,null,P,q,ji(m,R),F,!1),H>0){if(H&16)j(T,ne,J,P,R);else if(H&2&&ne.class!==J.class&&r(T,"class",null,J.class,R),H&4&&r(T,"style",ne.style,J.style,R),H&8){const _e=m.dynamicProps;for(let Ie=0;Ie<_e.length;Ie++){const Me=_e[Ie],nt=ne[Me],ot=J[Me];(ot!==nt||Me==="value")&&r(T,Me,nt,ot,R,P)}}H&1&&p.children!==m.children&&c(T,m.children)}else!I&&N==null&&j(T,ne,J,P,R);((ce=J.onVnodeUpdated)||se)&&rt(()=>{ce&&It(ce,P,m,p),se&&ln(m,p,P,"updated")},q)},O=(p,m,P,q,R,F,I)=>{for(let T=0;T<m.length;T++){const H=p[T],N=m[T],se=H.el&&(H.type===ye||!un(H,N)||H.shapeFlag&198)?d(H.el):P;y(H,N,se,null,q,R,F,I,!0)}},j=(p,m,P,q,R)=>{if(m!==P){if(m!==me)for(const F in m)!In(F)&&!(F in P)&&r(p,F,m[F],null,R,q);for(const F in P){if(In(F))continue;const I=P[F],T=m[F];I!==T&&F!=="value"&&r(p,F,T,I,R,q)}"value"in P&&r(p,"value",m.value,P.value,R)}},M=(p,m,P,q,R,F,I,T,H)=>{const N=m.el=p?p.el:l(""),se=m.anchor=p?p.anchor:l("");let{patchFlag:ne,dynamicChildren:J,slotScopeIds:ce}=m;ce&&(T=T?T.concat(ce):ce),p==null?(o(N,P,q),o(se,P,q),Z(m.children||[],P,se,R,F,I,T,H)):ne>0&&ne&64&&J&&p.dynamicChildren?(O(p.dynamicChildren,J,P,R,F,I,T),(m.key!=null||R&&m===R.subTree)&&Vs(p,m,!0)):x(p,m,P,se,R,F,I,T,H)},G=(p,m,P,q,R,F,I,T,H)=>{m.slotScopeIds=T,p==null?m.shapeFlag&512?R.ctx.activate(m,P,q,I,H):C(m,P,q,R,F,I,H):ee(p,m,H)},C=(p,m,P,q,R,F,I)=>{const T=p.component=Bu(p,q,R);if(Oo(p)&&(T.ctx.renderer=De),Nu(T,!1,I),T.asyncDep){if(R&&R.registerDep(T,W,I),!p.el){const H=T.subTree=V(qe);k(null,H,m,P),p.placeholder=H.el}}else W(T,p,m,P,R,F,I)},ee=(p,m,P)=>{const q=m.component=p.component;if(Eu(p,m,P))if(q.asyncDep&&!q.asyncResolved){S(q,m,P);return}else q.next=m,q.update();else m.el=p.el,q.vnode=m},W=(p,m,P,q,R,F,I)=>{const T=()=>{if(p.isMounted){let{next:ne,bu:J,u:ce,parent:_e,vnode:Ie}=p;{const Lt=Rs(p);if(Lt){ne&&(ne.el=Ie.el,S(p,ne,I)),Lt.asyncDep.then(()=>{p.isUnmounted||T()});return}}let Me=ne,nt;cn(p,!1),ne?(ne.el=Ie.el,S(p,ne,I)):ne=Ie,J&&fo(J),(nt=ne.props&&ne.props.onVnodeBeforeUpdate)&&It(nt,_e,ne,Ie),cn(p,!0);const ot=Ks(p),At=p.subTree;p.subTree=ot,y(At,ot,d(At.el),Ae(At),p,R,F),ne.el=ot.el,Me===null&&Iu(p,ot.el),ce&&rt(ce,R),(nt=ne.props&&ne.props.onVnodeUpdated)&&rt(()=>It(nt,_e,ne,Ie),R)}else{let ne;const{el:J,props:ce}=m,{bm:_e,m:Ie,parent:Me,root:nt,type:ot}=p,At=Sn(m);cn(p,!1),_e&&fo(_e),!At&&(ne=ce&&ce.onVnodeBeforeMount)&&It(ne,Me,m),cn(p,!0);{nt.ce&&nt.ce._def.shadowRoot!==!1&&nt.ce._injectChildStyle(ot);const Lt=p.subTree=Ks(p);y(null,Lt,P,q,p,R,F),m.el=Lt.el}if(Ie&&rt(Ie,R),!At&&(ne=ce&&ce.onVnodeMounted)){const Lt=m;rt(()=>It(ne,Me,Lt),R)}(m.shapeFlag&256||Me&&Sn(Me.vnode)&&Me.vnode.shapeFlag&256)&&p.a&&rt(p.a,R),p.isMounted=!0,m=P=q=null}};p.scope.on();const H=p.effect=new Ar(T);p.scope.off();const N=p.update=H.run.bind(H),se=p.job=H.runIfDirty.bind(H);se.i=p,se.id=p.uid,H.scheduler=()=>Ci(se),cn(p,!0),N()},S=(p,m,P)=>{m.component=p;const q=p.vnode.props;p.vnode=m,p.next=null,fu(p,m.props,q,P),mu(p,m.children,P),Ct(),rs(p),Tt()},x=(p,m,P,q,R,F,I,T,H=!1)=>{const N=p&&p.children,se=p?p.shapeFlag:0,ne=m.children,{patchFlag:J,shapeFlag:ce}=m;if(J>0){if(J&128){K(N,ne,P,q,R,F,I,T,H);return}else if(J&256){U(N,ne,P,q,R,F,I,T,H);return}}ce&8?(se&16&&we(N,R,F),ne!==N&&c(P,ne)):se&16?ce&16?K(N,ne,P,q,R,F,I,T,H):we(N,R,F,!0):(se&8&&c(P,""),ce&16&&Z(ne,P,q,R,F,I,T,H))},U=(p,m,P,q,R,F,I,T,H)=>{p=p||vt,m=m||vt;const N=p.length,se=m.length,ne=Math.min(N,se);let J;for(J=0;J<ne;J++){const ce=m[J]=H?Jt(m[J]):Et(m[J]);y(p[J],ce,P,null,R,F,I,T,H)}N>se?we(p,R,F,!0,!1,ne):Z(m,P,q,R,F,I,T,H,ne)},K=(p,m,P,q,R,F,I,T,H)=>{let N=0;const se=m.length;let ne=p.length-1,J=se-1;for(;N<=ne&&N<=J;){const ce=p[N],_e=m[N]=H?Jt(m[N]):Et(m[N]);if(un(ce,_e))y(ce,_e,P,null,R,F,I,T,H);else break;N++}for(;N<=ne&&N<=J;){const ce=p[ne],_e=m[J]=H?Jt(m[J]):Et(m[J]);if(un(ce,_e))y(ce,_e,P,null,R,F,I,T,H);else break;ne--,J--}if(N>ne){if(N<=J){const ce=J+1,_e=ce<se?m[ce].el:q;for(;N<=J;)y(null,m[N]=H?Jt(m[N]):Et(m[N]),P,_e,R,F,I,T,H),N++}}else if(N>J)for(;N<=ne;)fe(p[N],R,F,!0),N++;else{const ce=N,_e=N,Ie=new Map;for(N=_e;N<=J;N++){const ct=m[N]=H?Jt(m[N]):Et(m[N]);ct.key!=null&&Ie.set(ct.key,N)}let Me,nt=0;const ot=J-_e+1;let At=!1,Lt=0;const ro=new Array(ot);for(N=0;N<ot;N++)ro[N]=0;for(N=ce;N<=ne;N++){const ct=p[N];if(nt>=ot){fe(ct,R,F,!0);continue}let jt;if(ct.key!=null)jt=Ie.get(ct.key);else for(Me=_e;Me<=J;Me++)if(ro[Me-_e]===0&&un(ct,m[Me])){jt=Me;break}jt===void 0?fe(ct,R,F,!0):(ro[jt-_e]=N+1,jt>=Lt?Lt=jt:At=!0,y(ct,m[jt],P,null,R,F,I,T,H),nt++)}const Ha=At?wu(ro):vt;for(Me=Ha.length-1,N=ot-1;N>=0;N--){const ct=_e+N,jt=m[ct],Fa=m[ct+1],Wa=ct+1<se?Fa.el||Fa.placeholder:q;ro[N]===0?y(null,jt,P,Wa,R,F,I,T,H):At&&(Me<0||N!==Ha[Me]?D(jt,P,Wa,2):Me--)}}},D=(p,m,P,q,R=null)=>{const{el:F,type:I,transition:T,children:H,shapeFlag:N}=p;if(N&6){D(p.component.subTree,m,P,q);return}if(N&128){p.suspense.move(m,P,q);return}if(N&64){I.move(p,m,P,De);return}if(I===ye){o(F,m,P);for(let ne=0;ne<H.length;ne++)D(H[ne],m,P,q);o(p.anchor,m,P);return}if(I===Bo){A(p,m,P);return}if(q!==2&&N&1&&T)if(q===0)T.beforeEnter(F),o(F,m,P),rt(()=>T.enter(F),R);else{const{leave:ne,delayLeave:J,afterLeave:ce}=T,_e=()=>{p.ctx.isUnmounted?i(F):o(F,m,P)},Ie=()=>{F._isLeaving&&F[Rt](!0),ne(F,()=>{_e(),ce&&ce()})};J?J(F,_e,Ie):Ie()}else o(F,m,P)},fe=(p,m,P,q=!1,R=!1)=>{const{type:F,props:I,ref:T,children:H,dynamicChildren:N,shapeFlag:se,patchFlag:ne,dirs:J,cacheIndex:ce}=p;if(ne===-2&&(R=!1),T!=null&&(Ct(),Vn(T,null,P,p,!0),Tt()),ce!=null&&(m.renderCache[ce]=void 0),se&256){m.ctx.deactivate(p);return}const _e=se&1&&J,Ie=!Sn(p);let Me;if(Ie&&(Me=I&&I.onVnodeBeforeUnmount)&&It(Me,m,p),se&6)ve(p.component,P,q);else{if(se&128){p.suspense.unmount(P,q);return}_e&&ln(p,null,m,"beforeUnmount"),se&64?p.type.remove(p,m,P,De,q):N&&!N.hasOnce&&(F!==ye||ne>0&&ne&64)?we(N,m,P,!1,!0):(F===ye&&ne&384||!R&&se&16)&&we(H,m,P),q&&ae(p)}(Ie&&(Me=I&&I.onVnodeUnmounted)||_e)&&rt(()=>{Me&&It(Me,m,p),_e&&ln(p,null,m,"unmounted")},P)},ae=p=>{const{type:m,el:P,anchor:q,transition:R}=p;if(m===ye){he(P,q);return}if(m===Bo){b(p);return}const F=()=>{i(P),R&&!R.persisted&&R.afterLeave&&R.afterLeave()};if(p.shapeFlag&1&&R&&!R.persisted){const{leave:I,delayLeave:T}=R,H=()=>I(P,F);T?T(p.el,F,H):H()}else F()},he=(p,m)=>{let P;for(;p!==m;)P=f(p),i(p),p=P;i(m)},ve=(p,m,P)=>{const{bum:q,scope:R,job:F,subTree:I,um:T,m:H,a:N}=p;Hs(H),Hs(N),q&&fo(q),R.stop(),F&&(F.flags|=8,fe(I,p,m,P)),T&&rt(T,m),rt(()=>{p.isUnmounted=!0},m)},we=(p,m,P,q=!1,R=!1,F=0)=>{for(let I=F;I<p.length;I++)fe(p[I],m,P,q,R)},Ae=p=>{if(p.shapeFlag&6)return Ae(p.component.subTree);if(p.shapeFlag&128)return p.suspense.next();const m=f(p.anchor||p.el),P=m&&m[Hc];return P?f(P):m};let at=!1;const Je=(p,m,P)=>{p==null?m._vnode&&fe(m._vnode,null,null,!0):y(m._vnode||null,p,m,null,null,null,P),m._vnode=p,at||(at=!0,rs(),ss(),at=!1)},De={p:y,um:fe,m:D,r:ae,mt:C,mc:Z,pc:x,pbc:O,n:Ae,o:e};return{render:Je,hydrate:void 0,createApp:uu(Je)}}function ji({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 cn({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function yu(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Vs(e,t,n=!1){const o=e.children,i=t.children;if(re(o)&&re(i))for(let r=0;r<o.length;r++){const s=o[r];let l=i[r];l.shapeFlag&1&&!l.dynamicChildren&&((l.patchFlag<=0||l.patchFlag===32)&&(l=i[r]=Jt(i[r]),l.el=s.el),!n&&l.patchFlag!==-2&&Vs(s,l)),l.type===jo&&l.patchFlag!==-1&&(l.el=s.el),l.type===qe&&!l.el&&(l.el=s.el)}}function wu(e){const t=e.slice(),n=[0];let o,i,r,s,l;const a=e.length;for(o=0;o<a;o++){const u=e[o];if(u!==0){if(i=n[n.length-1],e[i]<u){t[o]=i,n.push(o);continue}for(r=0,s=n.length-1;r<s;)l=r+s>>1,e[n[l]]<u?r=l+1:s=l;u<e[n[r]]&&(r>0&&(t[o]=n[r-1]),n[r]=o)}}for(r=n.length,s=n[r-1];r-- >0;)n[r]=s,s=t[s];return n}function Rs(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Rs(t)}function Hs(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const xu=Symbol.for("v-scx"),_u=()=>Ft(xu);function Fs(e,t){return Ao(e,null,t)}function Su(e,t){return Ao(e,null,{flush:"sync"})}function de(e,t,n){return Ao(e,t,n)}function Ao(e,t,n=me){const{immediate:o,deep:i,flush:r,once:s}=n,l=Oe({},n),a=t&&o||!t&&r!=="post";let u;if(Zn){if(r==="sync"){const h=_u();u=h.__watcherHandles||(h.__watcherHandles=[])}else if(!a){const h=()=>{};return h.stop=kt,h.resume=kt,h.pause=kt,h}}const c=Ke;l.call=(h,w,y)=>wt(h,c,w,y);let d=!1;r==="post"?l.scheduler=h=>{rt(h,c&&c.suspense)}:r!=="sync"&&(d=!0,l.scheduler=(h,w)=>{w?h():Ci(h)}),l.augmentJob=h=>{t&&(h.flags|=4),d&&(h.flags|=2,c&&(h.id=c.uid,h.i=c))};const f=Dc(e,t,l);return Zn&&(u?u.push(f):a&&f()),f}function ku(e,t,n){const o=this.proxy,i=$e(e)?e.includes(".")?Ws(o,e):()=>o[e]:e.bind(o,o);let r;pe(t)?r=t:(r=t.handler,n=t);const s=Kn(this),l=Ao(i,r.bind(o),n);return s(),l}function Ws(e,t){const n=t.split(".");return()=>{let o=e;for(let i=0;i<n.length&&o;i++)o=o[n[i]];return o}}function st(e,t,n=me){const o=dn(),i=He(t),r=Qe(t),s=Us(e,i),l=ts((a,u)=>{let c,d=me,f;return Su(()=>{const h=e[i];et(c,h)&&(c=h,u())}),{get(){return a(),n.get?n.get(c):c},set(h){const w=n.set?n.set(h):h;if(!et(w,c)&&!(d!==me&&et(h,d)))return;const y=o.vnode.props;y&&(t in y||i in y||r in y)&&(`onUpdate:${t}`in y||`onUpdate:${i}`in y||`onUpdate:${r}`in y)||(c=h,u()),o.emit(`update:${t}`,w),et(h,w)&&et(h,d)&&!et(w,f)&&u(),d=h,f=w}}});return l[Symbol.iterator]=()=>{let a=0;return{next(){return a<2?{value:a++?s||me:l,done:!1}:{done:!0}}}},l}const Us=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${He(t)}Modifiers`]||e[`${Qe(t)}Modifiers`];function Cu(e,t,...n){if(e.isUnmounted)return;const o=e.vnode.props||me;let i=n;const r=t.startsWith("update:"),s=r&&Us(o,t.slice(7));s&&(s.trim&&(i=n.map(c=>$e(c)?c.trim():c)),s.number&&(i=n.map(ui)));let l,a=o[l=ci(t)]||o[l=ci(He(t))];!a&&r&&(a=o[l=ci(Qe(t))]),a&&wt(a,e,6,i);const u=o[l+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,wt(u,e,6,i)}}const Tu=new WeakMap;function qs(e,t,n=!1){const o=n?Tu:t.emitsCache,i=o.get(e);if(i!==void 0)return i;const r=e.emits;let s={},l=!1;if(!pe(e)){const a=u=>{const c=qs(u,t,!0);c&&(l=!0,Oe(s,c))};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}return!r&&!l?(Te(e)&&o.set(e,null),null):(re(r)?r.forEach(a=>s[a]=null):Oe(s,r),Te(e)&&o.set(e,s),s)}function Lo(e,t){return!e||!so(t)?!1:(t=t.slice(2).replace(/Once$/,""),ke(e,t[0].toLowerCase()+t.slice(1))||ke(e,Qe(t))||ke(e,t))}function Ym(){}function Ks(e){const{type:t,vnode:n,proxy:o,withProxy:i,propsOptions:[r],slots:s,attrs:l,emit:a,render:u,renderCache:c,props:d,data:f,setupState:h,ctx:w,inheritAttrs:y}=e,$=Po(e);let k,B;try{if(n.shapeFlag&4){const b=i||o,g=b;k=Et(u.call(g,b,c,d,h,f,w)),B=l}else{const b=t;k=Et(b.length>1?b(d,{attrs:l,slots:s,emit:a}):b(d,null)),B=t.props?l:Mu(l)}}catch(b){Wn.length=0,To(b,e,1),k=V(qe)}let A=k;if(B&&y!==!1){const b=Object.keys(B),{shapeFlag:g}=A;b.length&&g&7&&(r&&b.some(si)&&(B=Pu(B,r)),A=Gt(A,B,!1,!0))}return n.dirs&&(A=Gt(A,null,!1,!0),A.dirs=A.dirs?A.dirs.concat(n.dirs):n.dirs),n.transition&&Nn(A,n.transition),k=A,Po($),k}const Mu=e=>{let t;for(const n in e)(n==="class"||n==="style"||so(n))&&((t||(t={}))[n]=e[n]);return t},Pu=(e,t)=>{const n={};for(const o in e)(!si(o)||!(o.slice(9)in t))&&(n[o]=e[o]);return n};function Eu(e,t,n){const{props:o,children:i,component:r}=e,{props:s,children:l,patchFlag:a}=t,u=r.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&a>=0){if(a&1024)return!0;if(a&16)return o?Zs(o,s,u):!!s;if(a&8){const c=t.dynamicProps;for(let d=0;d<c.length;d++){const f=c[d];if(s[f]!==o[f]&&!Lo(u,f))return!0}}}else return(i||l)&&(!l||!l.$stable)?!0:o===s?!1:o?s?Zs(o,s,u):!0:!!s;return!1}function Zs(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let i=0;i<o.length;i++){const r=o[i];if(t[r]!==e[r]&&!Lo(n,r))return!0}return!1}function Iu({vnode:e,parent:t},n){for(;t;){const o=t.subTree;if(o.suspense&&o.suspense.activeBranch===e&&(o.el=e.el),o===e)(e=t.vnode).el=n,t=t.parent;else break}}const Ys=e=>e.__isSuspense;function Ou(e,t){t&&t.pendingBranch?re(e)?t.effects.push(...e):t.effects.push(e):Rc(e)}const ye=Symbol.for("v-fgt"),jo=Symbol.for("v-txt"),qe=Symbol.for("v-cmt"),Bo=Symbol.for("v-stc"),Wn=[];let lt=null;function v(e=!1){Wn.push(lt=e?null:[])}function $u(){Wn.pop(),lt=Wn[Wn.length-1]||null}let Un=1;function No(e,t=!1){Un+=e,e<0&<&&t&&(lt.hasOnce=!0)}function Xs(e){return e.dynamicChildren=Un>0?lt||vt:null,$u(),Un>0&<&<.push(e),e}function z(e,t,n,o,i,r){return Xs(Y(e,t,n,o,i,r,!0))}function ie(e,t,n,o,i){return Xs(V(e,t,n,o,i,!0))}function qn(e){return e?e.__v_isVNode===!0:!1}function un(e,t){return e.type===t.type&&e.key===t.key}const Gs=({key:e})=>e??null,Vo=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?$e(e)||ze(e)||pe(e)?{i:Ve,r:e,k:t,f:!!n}:e:null);function Y(e,t=null,n=null,o=0,i=null,r=e===ye?0:1,s=!1,l=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Gs(t),ref:t&&Vo(t),scopeId:as,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:r,patchFlag:o,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Ve};return l?(Bi(a,n),r&128&&e.normalize(a)):n&&(a.shapeFlag|=$e(n)?8:16),Un>0&&!s&<&&(a.patchFlag>0||r&6)&&a.patchFlag!==32&<.push(a),a}const V=zu;function zu(e,t=null,n=null,o=0,i=null,r=!1){if((!e||e===ws)&&(e=qe),qn(e)){const l=Gt(e,t,!0);return n&&Bi(l,n),Un>0&&!r&<&&(l.shapeFlag&6?lt[lt.indexOf(e)]=l:lt.push(l)),l.patchFlag=-2,l}if(Uu(e)&&(e=e.__vccOpts),t){t=Du(t);let{class:l,style:a}=t;l&&!$e(l)&&(t.class=ue(l)),Te(a)&&(Si(a)&&!re(a)&&(a=Oe({},a)),t.style=Ce(a))}const s=$e(e)?1:Ys(e)?128:cs(e)?64:Te(e)?4:pe(e)?2:0;return Y(e,t,n,o,i,s,r,!0)}function Du(e){return e?Si(e)||zs(e)?Oe({},e):e:null}function Gt(e,t,n=!1,o=!1){const{props:i,ref:r,patchFlag:s,children:l,transition:a}=e,u=t?kn(i||{},t):i,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&Gs(u),ref:t&&t.ref?n&&r?re(r)?r.concat(Vo(t)):[r,Vo(t)]:Vo(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ye?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:a,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Gt(e.ssContent),ssFallback:e.ssFallback&&Gt(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return a&&o&&Nn(c,a.clone(c)),c}function Wt(e=" ",t=0){return V(jo,null,e,t)}function Au(e,t){const n=V(Bo,null,e);return n.staticCount=t,n}function le(e="",t=!1){return t?(v(),ie(qe,null,e)):V(qe,null,e)}function Et(e){return e==null||typeof e=="boolean"?V(qe):re(e)?V(ye,null,e.slice()):qn(e)?Jt(e):V(jo,null,String(e))}function Jt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Gt(e)}function Bi(e,t){let n=0;const{shapeFlag:o}=e;if(t==null)t=null;else if(re(t))n=16;else if(typeof t=="object")if(o&65){const i=t.default;i&&(i._c&&(i._d=!1),Bi(e,i()),i._c&&(i._d=!0));return}else{n=32;const i=t._;!i&&!zs(t)?t._ctx=Ve:i===3&&Ve&&(Ve.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else pe(t)?(t={default:t,_ctx:Ve},n=32):(t=String(t),o&64?(n=16,t=[Wt(t)]):n=8);e.children=t,e.shapeFlag|=n}function kn(...e){const t={};for(let n=0;n<e.length;n++){const o=e[n];for(const i in o)if(i==="class")t.class!==o.class&&(t.class=ue([t.class,o.class]));else if(i==="style")t.style=Ce([t.style,o.style]);else if(so(i)){const r=t[i],s=o[i];s&&r!==s&&!(re(r)&&r.includes(s))&&(t[i]=r?[].concat(r,s):s)}else i!==""&&(t[i]=o[i])}return t}function It(e,t,n,o=null){wt(e,t,7,[n,o])}const Lu=Es();let ju=0;function Bu(e,t,n){const o=e.type,i=(t?t.appContext:e.appContext)||Lu,r={uid:ju++,vnode:e,type:o,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new tc(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:As(o,i),emitsOptions:qs(o,i),emit:null,emitted:null,propsDefaults:me,inheritAttrs:o.inheritAttrs,ctx:me,data:me,props:me,attrs:me,slots:me,refs:me,setupState:me,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 r.ctx={_:r},r.root=t?t.root:r,r.emit=Cu.bind(null,r),e.ce&&e.ce(r),r}let Ke=null;const dn=()=>Ke||Ve;let Ro,Ni;{const e=po(),t=(n,o)=>{let i;return(i=e[n])||(i=e[n]=[]),i.push(o),r=>{i.length>1?i.forEach(s=>s(r)):i[0](r)}};Ro=t("__VUE_INSTANCE_SETTERS__",n=>Ke=n),Ni=t("__VUE_SSR_SETTERS__",n=>Zn=n)}const Kn=e=>{const t=Ke;return Ro(e),e.scope.on(),()=>{e.scope.off(),Ro(t)}},Js=()=>{Ke&&Ke.scope.off(),Ro(null)};function Qs(e){return e.vnode.shapeFlag&4}let Zn=!1;function Nu(e,t=!1,n=!1){t&&Ni(t);const{props:o,children:i}=e.vnode,r=Qs(e);du(e,o,r,t),gu(e,i,n||t);const s=r?Vu(e,t):void 0;return t&&Ni(!1),s}function Vu(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,ou);const{setup:o}=n;if(o){Ct();const i=e.setupContext=o.length>1?Hu(e):null,r=Kn(e),s=wn(o,e,0,[e.props,i]),l=Mr(s);if(Tt(),r(),(l||e.sp)&&!Sn(e)&&ms(e),l){if(s.then(Js,Js),t)return s.then(a=>{el(e,a)}).catch(a=>{To(a,e,0)});e.asyncDep=s}else el(e,s)}else tl(e)}function el(e,t,n){pe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Te(t)&&(e.setupState=es(t)),tl(e)}function tl(e,t,n){const o=e.type;e.render||(e.render=o.render||kt);{const i=Kn(e);Ct();try{iu(e)}finally{Tt(),i()}}}const Ru={get(e,t){return Ue(e,"get",""),e[t]}};function Hu(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,Ru),slots:e.slots,emit:e.emit,expose:t}}function Ho(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(es(Sc(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Rn)return Rn[n](e)},has(t,n){return n in t||n in Rn}})):e.proxy}const Fu=/(?:^|[-_])\w/g,Wu=e=>e.replace(Fu,t=>t.toUpperCase()).replace(/[-_]/g,"");function nl(e,t=!0){return pe(e)?e.displayName||e.name:e.name||t&&e.__name}function ol(e,t,n=!1){let o=nl(t);if(!o&&t.__file){const i=t.__file.match(/([^/\\]+)\.\w+$/);i&&(o=i[1])}if(!o&&e&&e.parent){const i=r=>{for(const s in r)if(r[s]===t)return s};o=i(e.components||e.parent.type.components)||i(e.appContext.components)}return o?Wu(o):n?"App":"Anonymous"}function Uu(e){return pe(e)&&"__vccOpts"in e}const Q=(e,t)=>$c(e,t,Zn);function il(e,t,n){try{No(-1);const o=arguments.length;return o===2?Te(t)&&!re(t)?qn(t)?V(e,null,[t]):V(e,t):V(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):o===3&&qn(n)&&(n=[n]),V(e,t,n))}finally{No(1)}}const qu="3.5.24";/**
|
|
15
|
+
`,...Yc(i)),console.warn(...r)}Pt(),Ti=!1}function Zc(){let e=Rn[Rn.length-1];if(!e)return[];const t=[];for(;e;){const n=t[0];n&&n.vnode===e?n.recurseCount++:t.push({vnode:e,recurseCount:0});const o=e.component&&e.component.parent;e=o&&o.vnode}return t}function Yc(e){const t=[];return e.forEach((n,o)=>{t.push(...o===0?[]:[`
|
|
16
|
+
`],...Xc(n))}),t}function Xc({vnode:e,recurseCount:t}){const n=t>0?`... (${t} recursive calls)`:"",o=e.component?e.component.parent==null:!1,i=` at <${cl(e.component,e.type,o)}`,r=">"+n;return e.props?[i,...Gc(e.props),r]:[i+r]}function Gc(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach(o=>{t.push(...as(o,e[o]))}),n.length>3&&t.push(" ..."),t}function as(e,t,n){return De(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):typeof t=="number"||typeof t=="boolean"||t==null?n?t:[`${e}=${t}`]:ze(t)?(t=as(e,_e(t.value),!0),n?t:[`${e}=Ref<`,t,">"]):he(t)?[`${e}=fn${t.name?`<${t.name}>`:""}`]:(t=_e(t),n?t:[`${e}=`,t])}function kn(e,t,n,o){try{return o?e(...o):e()}catch(i){Po(i,t,n)}}function xt(e,t,n,o){if(he(e)){const i=kn(e,t,n,o);return i&&Dr(i)&&i.catch(r=>{Po(r,t,n)}),i}if(le(e)){const i=[];for(let r=0;r<e.length;r++)i.push(xt(e[r],t,n,o));return i}}function Po(e,t,n,o=!0){const i=t?t.vnode:null,{errorHandler:r,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||me;if(t){let l=t.parent;const a=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${n}`;for(;l;){const c=l.ec;if(c){for(let d=0;d<c.length;d++)if(c[d](e,a,u)===!1)return}l=l.parent}if(r){Tt(),kn(r,null,10,[e,a,u]),Pt();return}}Jc(e,n,i,o,s)}function Jc(e,t,n,o=!0,i=!1){if(i)throw e;console.error(e)}const Ye=[];let It=-1;const Cn=[];let Xt=null,Tn=0;const cs=Promise.resolve();let Io=null;function pt(e){const t=Io||cs;return e?t.then(this?e.bind(this):e):t}function Qc(e){let t=It+1,n=Ye.length;for(;t<n;){const o=t+n>>>1,i=Ye[o],r=Hn(i);r<e||r===e&&i.flags&2?t=o+1:n=o}return t}function Pi(e){if(!(e.flags&1)){const t=Hn(e),n=Ye[Ye.length-1];!n||!(e.flags&2)&&t>=Hn(n)?Ye.push(e):Ye.splice(Qc(t),0,e),e.flags|=1,us()}}function us(){Io||(Io=cs.then(ps))}function eu(e){le(e)?Cn.push(...e):Xt&&e.id===-1?Xt.splice(Tn+1,0,e):e.flags&1||(Cn.push(e),e.flags|=1),us()}function ds(e,t,n=It+1){for(;n<Ye.length;n++){const o=Ye[n];if(o&&o.flags&2){if(e&&o.id!==e.uid)continue;Ye.splice(n,1),n--,o.flags&4&&(o.flags&=-2),o(),o.flags&4||(o.flags&=-2)}}}function fs(e){if(Cn.length){const t=[...new Set(Cn)].sort((n,o)=>Hn(n)-Hn(o));if(Cn.length=0,Xt){Xt.push(...t);return}for(Xt=t,Tn=0;Tn<Xt.length;Tn++){const n=Xt[Tn];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}Xt=null,Tn=0}}const Hn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function ps(e){try{for(It=0;It<Ye.length;It++){const t=Ye[It];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),kn(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;It<Ye.length;It++){const t=Ye[It];t&&(t.flags&=-2)}It=-1,Ye.length=0,fs(),Io=null,(Ye.length||Cn.length)&&ps()}}let Re=null,hs=null;function Eo(e){const t=Re;return Re=e,hs=e&&e.type.__scopeId||null,t}function oe(e,t=Re,n){if(!t||e._n)return e;const o=(...i)=>{o._d&&Vo(-1);const r=Eo(t);let s;try{s=e(...i)}finally{Eo(r),o._d&&Vo(1)}return s};return o._n=!0,o._c=!0,o._d=!0,o}function He(e,t){if(Re===null)return e;const n=Fo(Re),o=e.dirs||(e.dirs=[]);for(let i=0;i<t.length;i++){let[r,s,l,a=me]=t[i];r&&(he(r)&&(r={mounted:r,updated:r}),r.deep&&Rt(s),o.push({dir:r,instance:n,value:s,oldValue:void 0,arg:l,modifiers:a}))}return e}function an(e,t,n,o){const i=e.dirs,r=t&&t.dirs;for(let s=0;s<i.length;s++){const l=i[s];r&&(l.oldValue=r[s].value);let a=l.dir[o];a&&(Tt(),xt(a,n,8,[e.el,l,e,t]),Pt())}}const tu=Symbol("_vte"),gs=e=>e.__isTeleport,Ht=Symbol("_leaveCb"),Mo=Symbol("_enterCb");function nu(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return je(()=>{e.isMounted=!0}),Mi(()=>{e.isUnmounting=!0}),e}const ht=[Function,Array],ms={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:ht,onEnter:ht,onAfterEnter:ht,onEnterCancelled:ht,onBeforeLeave:ht,onLeave:ht,onAfterLeave:ht,onLeaveCancelled:ht,onBeforeAppear:ht,onAppear:ht,onAfterAppear:ht,onAppearCancelled:ht},vs=e=>{const t=e.subTree;return t.component?vs(t.component):t},ou={name:"BaseTransition",props:ms,setup(e,{slots:t}){const n=fn(),o=nu();return()=>{const i=t.default&&xs(t.default(),!0);if(!i||!i.length)return;const r=bs(i),s=_e(e),{mode:l}=s;if(o.isLeaving)return Ei(r);const a=ws(r);if(!a)return Ei(r);let u=Ii(a,s,o,n,d=>u=d);a.type!==Ke&&Fn(a,u);let c=n.subTree&&ws(n.subTree);if(c&&c.type!==Ke&&!dn(c,a)&&vs(n).type!==Ke){let d=Ii(c,s,o,n);if(Fn(c,d),l==="out-in"&&a.type!==Ke)return o.isLeaving=!0,d.afterLeave=()=>{o.isLeaving=!1,n.job.flags&8||n.update(),delete d.afterLeave,c=void 0},Ei(r);l==="in-out"&&a.type!==Ke?d.delayLeave=(f,p,b)=>{const y=ys(o,c);y[String(c.key)]=c,f[Ht]=()=>{p(),f[Ht]=void 0,delete u.delayedLeave,c=void 0},u.delayedLeave=()=>{b(),delete u.delayedLeave,c=void 0}}:c=void 0}else c&&(c=void 0);return r}}};function bs(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==Ke){t=n;break}}return t}const iu=ou;function ys(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function Ii(e,t,n,o,i){const{appear:r,mode:s,persisted:l=!1,onBeforeEnter:a,onEnter:u,onAfterEnter:c,onEnterCancelled:d,onBeforeLeave:f,onLeave:p,onAfterLeave:b,onLeaveCancelled:y,onBeforeAppear:$,onAppear:k,onAfterAppear:B,onAppearCancelled:F}=t,C=String(e.key),g=ys(n,e),T=(w,M)=>{w&&xt(w,o,9,M)},x=(w,M)=>{const W=M[1];T(w,M),le(w)?w.every(A=>A.length<=1)&&W():w.length<=1&&W()},z={mode:s,persisted:l,beforeEnter(w){let M=a;if(!n.isMounted)if(r)M=$||a;else return;w[Ht]&&w[Ht](!0);const W=g[C];W&&dn(e,W)&&W.el[Ht]&&W.el[Ht](),T(M,[w])},enter(w){let M=u,W=c,A=d;if(!n.isMounted)if(r)M=k||u,W=B||c,A=F||d;else return;let X=!1;const I=w[Mo]=ne=>{X||(X=!0,ne?T(A,[w]):T(W,[w]),z.delayedLeave&&z.delayedLeave(),w[Mo]=void 0)};M?x(M,[w,I]):I()},leave(w,M){const W=String(e.key);if(w[Mo]&&w[Mo](!0),n.isUnmounting)return M();T(f,[w]);let A=!1;const X=w[Ht]=I=>{A||(A=!0,M(),I?T(y,[w]):T(b,[w]),w[Ht]=void 0,g[W]===e&&delete g[W])};g[W]=e,p?x(p,[w,X]):X()},clone(w){const M=Ii(w,t,n,o,i);return i&&i(M),M}};return z}function Ei(e){if($o(e))return e=Jt(e),e.children=null,e}function ws(e){if(!$o(e))return gs(e.type)&&e.children?bs(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&&he(n.default))return n.default()}}function Fn(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Fn(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 xs(e,t=!1,n){let o=[],i=0;for(let r=0;r<e.length;r++){let s=e[r];const l=n==null?s.key:String(n)+String(s.key!=null?s.key:r);s.type===we?(s.patchFlag&128&&i++,o=o.concat(xs(s.children,t,l))):(t||s.type!==Ke)&&o.push(l!=null?Jt(s,{key:l}):s)}if(i>1)for(let r=0;r<o.length;r++)o[r].patchFlag=-2;return o}function ge(e,t){return he(e)?$e({name:e.name},t,{setup:e}):e}function _s(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}const Oo=new WeakMap;function Wn(e,t,n,o,i=!1){if(le(e)){e.forEach((b,y)=>Wn(b,t&&(le(t)?t[y]:t),n,o,i));return}if(Pn(o)&&!i){o.shapeFlag&512&&o.type.__asyncResolved&&o.component.subTree.component&&Wn(e,t,n,o.component.subTree);return}const r=o.shapeFlag&4?Fo(o.component):o.el,s=i?null:r,{i:l,r:a}=e,u=t&&t.r,c=l.refs===me?l.refs={}:l.refs,d=l.setupState,f=_e(d),p=d===me?Or:b=>Ce(f,b);if(u!=null&&u!==a){if(Ss(t),De(u))c[u]=null,p(u)&&(d[u]=null);else if(ze(u)){u.value=null;const b=t;b.k&&(c[b.k]=null)}}if(he(a))kn(a,l,12,[s,c]);else{const b=De(a),y=ze(a);if(b||y){const $=()=>{if(e.f){const k=b?p(a)?d[a]:c[a]:a.value;if(i)le(k)&&ci(k,r);else if(le(k))k.includes(r)||k.push(r);else if(b)c[a]=[r],p(a)&&(d[a]=c[a]);else{const B=[r];a.value=B,e.k&&(c[e.k]=B)}}else b?(c[a]=s,p(a)&&(d[a]=s)):y&&(a.value=s,e.k&&(c[e.k]=s))};if(s){const k=()=>{$(),Oo.delete(e)};k.id=-1,Oo.set(e,k),st(k,n)}else Ss(e),$()}}}function Ss(e){const t=Oo.get(e);t&&(t.flags|=8,Oo.delete(e))}ho().requestIdleCallback,ho().cancelIdleCallback;const Pn=e=>!!e.type.__asyncLoader,$o=e=>e.type.__isKeepAlive;function ru(e,t){ks(e,"a",t)}function su(e,t){ks(e,"da",t)}function ks(e,t,n=Ze){const o=e.__wdc||(e.__wdc=()=>{let i=n;for(;i;){if(i.isDeactivated)return;i=i.parent}return e()});if(Do(t,o,n),n){let i=n.parent;for(;i&&i.parent;)$o(i.parent.vnode)&&lu(o,t,n,i),i=i.parent}}function lu(e,t,n,o){const i=Do(t,e,o,!0);Et(()=>{ci(o[t],i)},n)}function Do(e,t,n=Ze,o=!1){if(n){const i=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...s)=>{Tt();const l=Gn(n),a=xt(t,n,e,s);return l(),Pt(),a});return o?i.unshift(r):i.push(r),r}}const Ft=e=>(t,n=Ze)=>{(!Jn||e==="sp")&&Do(e,(...o)=>t(...o),n)},au=Ft("bm"),je=Ft("m"),cu=Ft("bu"),uu=Ft("u"),Mi=Ft("bum"),Et=Ft("um"),du=Ft("sp"),fu=Ft("rtg"),pu=Ft("rtc");function Cs(e,t=Ze){Do("ec",e,t)}const hu="components",Ts=Symbol.for("v-ndc");function Ps(e){return De(e)?gu(hu,e,!1)||e:e||Ts}function gu(e,t,n=!0,o=!1){const i=Re||Ze;if(i){const r=i.type;{const l=al(r,!1);if(l&&(l===t||l===Fe(t)||l===fo(Fe(t))))return r}const s=Is(i[e]||r[e],t)||Is(i.appContext[e],t);return!s&&o?r:s}}function Is(e,t){return e&&(e[t]||e[Fe(t)]||e[fo(Fe(t))])}function Gt(e,t,n,o){let i;const r=n,s=le(e);if(s||De(e)){const l=s&&Sn(e);let a=!1,u=!1;l&&(a=!ut(e),u=Yt(e),e=bo(e)),i=new Array(e.length);for(let c=0,d=e.length;c<d;c++)i[c]=t(a?u?ko(Ve(e[c])):Ve(e[c]):e[c],c,void 0,r)}else if(typeof e=="number"){i=new Array(e);for(let l=0;l<e;l++)i[l]=t(l+1,l,void 0,r)}else if(Ie(e))if(e[Symbol.iterator])i=Array.from(e,(l,a)=>t(l,a,void 0,r));else{const l=Object.keys(e);i=new Array(l.length);for(let a=0,u=l.length;a<u;a++){const c=l[a];i[a]=t(e[c],c,a,r)}}else i=[];return i}function Oi(e,t){for(let n=0;n<t.length;n++){const o=t[n];if(le(o))for(let i=0;i<o.length;i++)e[o[i].name]=o[i].fn;else o&&(e[o.name]=o.key?(...i)=>{const r=o.fn(...i);return r&&(r.key=o.key),r}:o.fn)}return e}function ke(e,t,n={},o,i){if(Re.ce||Re.parent&&Pn(Re.parent)&&Re.parent.ce){const u=Object.keys(n).length>0;return t!=="default"&&(n.name=t),v(),re(we,null,[j("slot",n,o&&o())],u?-2:64)}let r=e[t];r&&r._c&&(r._d=!1),v();const s=r&&Es(r(n)),l=n.key||s&&s.key,a=re(we,{key:(l&&!yt(l)?l:`_${t}`)+(!s&&o?"_fb":"")},s||(o?o():[]),s&&e._===1?64:-2);return a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),r&&r._c&&(r._d=!0),a}function Es(e){return e.some(t=>Xn(t)?!(t.type===Ke||t.type===we&&!Es(t.children)):!0)?e:null}const $i=e=>e?rl(e)?Fo(e):$i(e.parent):null,qn=$e(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=>$i(e.parent),$root:e=>$i(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>$s(e),$forceUpdate:e=>e.f||(e.f=()=>{Pi(e.update)}),$nextTick:e=>e.n||(e.n=pt.bind(e.proxy)),$watch:e=>Lu.bind(e)}),Di=(e,t)=>e!==me&&!e.__isScriptSetup&&Ce(e,t),mu={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:o,data:i,props:r,accessCache:s,type:l,appContext:a}=e;let u;if(t[0]!=="$"){const p=s[t];if(p!==void 0)switch(p){case 1:return o[t];case 2:return i[t];case 4:return n[t];case 3:return r[t]}else{if(Di(o,t))return s[t]=1,o[t];if(i!==me&&Ce(i,t))return s[t]=2,i[t];if((u=e.propsOptions[0])&&Ce(u,t))return s[t]=3,r[t];if(n!==me&&Ce(n,t))return s[t]=4,n[t];zi&&(s[t]=0)}}const c=qn[t];let d,f;if(c)return t==="$attrs"&&Ue(e.attrs,"get",""),c(e);if((d=l.__cssModules)&&(d=d[t]))return d;if(n!==me&&Ce(n,t))return s[t]=4,n[t];if(f=a.config.globalProperties,Ce(f,t))return f[t]},set({_:e},t,n){const{data:o,setupState:i,ctx:r}=e;return Di(i,t)?(i[t]=n,!0):o!==me&&Ce(o,t)?(o[t]=n,!0):Ce(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:i,propsOptions:r,type:s}},l){let a,u;return!!(n[l]||e!==me&&l[0]!=="$"&&Ce(e,l)||Di(t,l)||(a=r[0])&&Ce(a,l)||Ce(o,l)||Ce(qn,l)||Ce(i.config.globalProperties,l)||(u=s.__cssModules)&&u[l])},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 zo(e){return le(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function Xe(e,t){return!e||!t?e||t:le(e)&&le(t)?e.concat(t):$e({},zo(e),zo(t))}let zi=!0;function vu(e){const t=$s(e),n=e.proxy,o=e.ctx;zi=!1,t.beforeCreate&&Ms(t.beforeCreate,e,"bc");const{data:i,computed:r,methods:s,watch:l,provide:a,inject:u,created:c,beforeMount:d,mounted:f,beforeUpdate:p,updated:b,activated:y,deactivated:$,beforeDestroy:k,beforeUnmount:B,destroyed:F,unmounted:C,render:g,renderTracked:T,renderTriggered:x,errorCaptured:z,serverPrefetch:w,expose:M,inheritAttrs:W,components:A,directives:X,filters:I}=t;if(u&&bu(u,o,null),s)for(const P in s){const _=s[P];he(_)&&(o[P]=_.bind(n))}if(i){const P=i.call(n,n);Ie(P)&&(e.data=_o(P))}if(zi=!0,r)for(const P in r){const _=r[P],Y=he(_)?_.bind(n,n):he(_.get)?_.get.bind(n,n):Ct,se=!he(_)&&he(_.set)?_.set.bind(n):Ct,K=Q({get:Y,set:se});Object.defineProperty(o,P,{enumerable:!0,configurable:!0,get:()=>K.value,set:R=>K.value=R})}if(l)for(const P in l)Os(l[P],o,n,P);if(a){const P=he(a)?a.call(n):a;Reflect.ownKeys(P).forEach(_=>{Kn(_,P[_])})}c&&Ms(c,e,"c");function G(P,_){le(_)?_.forEach(Y=>P(Y.bind(n))):_&&P(_.bind(n))}if(G(au,d),G(je,f),G(cu,p),G(uu,b),G(ru,y),G(su,$),G(Cs,z),G(pu,T),G(fu,x),G(Mi,B),G(Et,C),G(du,w),le(M))if(M.length){const P=e.exposed||(e.exposed={});M.forEach(_=>{Object.defineProperty(P,_,{get:()=>n[_],set:Y=>n[_]=Y,enumerable:!0})})}else e.exposed||(e.exposed={});g&&e.render===Ct&&(e.render=g),W!=null&&(e.inheritAttrs=W),A&&(e.components=A),X&&(e.directives=X),w&&_s(e)}function bu(e,t,n=Ct){le(e)&&(e=Ai(e));for(const o in e){const i=e[o];let r;Ie(i)?"default"in i?r=Wt(i.from||o,i.default,!0):r=Wt(i.from||o):r=Wt(i),ze(r)?Object.defineProperty(t,o,{enumerable:!0,configurable:!0,get:()=>r.value,set:s=>r.value=s}):t[o]=r}}function Ms(e,t,n){xt(le(e)?e.map(o=>o.bind(t.proxy)):e.bind(t.proxy),t,n)}function Os(e,t,n,o){let i=o.includes(".")?Xs(n,o):()=>n[o];if(De(e)){const r=t[e];he(r)&&fe(i,r)}else if(he(e))fe(i,e.bind(n));else if(Ie(e))if(le(e))e.forEach(r=>Os(r,t,n,o));else{const r=he(e.handler)?e.handler.bind(n):t[e.handler];he(r)&&fe(i,r,e)}}function $s(e){const t=e.type,{mixins:n,extends:o}=t,{mixins:i,optionsCache:r,config:{optionMergeStrategies:s}}=e.appContext,l=r.get(t);let a;return l?a=l:!i.length&&!n&&!o?a=t:(a={},i.length&&i.forEach(u=>Ao(a,u,s,!0)),Ao(a,t,s)),Ie(t)&&r.set(t,a),a}function Ao(e,t,n,o=!1){const{mixins:i,extends:r}=t;r&&Ao(e,r,n,!0),i&&i.forEach(s=>Ao(e,s,n,!0));for(const s in t)if(!(o&&s==="expose")){const l=yu[s]||n&&n[s];e[s]=l?l(e[s],t[s]):t[s]}return e}const yu={data:Ds,props:zs,emits:zs,methods:Un,computed:Un,beforeCreate:Ge,created:Ge,beforeMount:Ge,mounted:Ge,beforeUpdate:Ge,updated:Ge,beforeDestroy:Ge,beforeUnmount:Ge,destroyed:Ge,unmounted:Ge,activated:Ge,deactivated:Ge,errorCaptured:Ge,serverPrefetch:Ge,components:Un,directives:Un,watch:xu,provide:Ds,inject:wu};function Ds(e,t){return t?e?function(){return $e(he(e)?e.call(this,this):e,he(t)?t.call(this,this):t)}:t:e}function wu(e,t){return Un(Ai(e),Ai(t))}function Ai(e){if(le(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Ge(e,t){return e?[...new Set([].concat(e,t))]:t}function Un(e,t){return e?$e(Object.create(null),e,t):t}function zs(e,t){return e?le(e)&&le(t)?[...new Set([...e,...t])]:$e(Object.create(null),zo(e),zo(t??{})):t}function xu(e,t){if(!e)return t;if(!t)return e;const n=$e(Object.create(null),e);for(const o in t)n[o]=Ge(e[o],t[o]);return n}function As(){return{app:null,config:{isNativeTag:Or,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 _u=0;function Su(e,t){return function(o,i=null){he(o)||(o=$e({},o)),i!=null&&!Ie(i)&&(i=null);const r=As(),s=new WeakSet,l=[];let a=!1;const u=r.app={_uid:_u++,_component:o,_props:i,_container:null,_context:r,_instance:null,version:rd,get config(){return r.config},set config(c){},use(c,...d){return s.has(c)||(c&&he(c.install)?(s.add(c),c.install(u,...d)):he(c)&&(s.add(c),c(u,...d))),u},mixin(c){return r.mixins.includes(c)||r.mixins.push(c),u},component(c,d){return d?(r.components[c]=d,u):r.components[c]},directive(c,d){return d?(r.directives[c]=d,u):r.directives[c]},mount(c,d,f){if(!a){const p=u._ceVNode||j(o,i);return p.appContext=r,f===!0?f="svg":f===!1&&(f=void 0),e(p,c,f),a=!0,u._container=c,c.__vue_app__=u,Fo(p.component)}},onUnmount(c){l.push(c)},unmount(){a&&(xt(l,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(c,d){return r.provides[c]=d,u},runWithContext(c){const d=cn;cn=u;try{return c()}finally{cn=d}}};return u}}let cn=null;function Kn(e,t){if(Ze){let n=Ze.provides;const o=Ze.parent&&Ze.parent.provides;o===n&&(n=Ze.provides=Object.create(o)),n[e]=t}}function Wt(e,t,n=!1){const o=fn();if(o||cn){let i=cn?cn._context.provides:o?o.parent==null||o.ce?o.vnode.appContext&&o.vnode.appContext.provides:o.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&he(t)?t.call(o&&o.proxy):t}}function Bs(){return!!(fn()||cn)}const Ls={},js=()=>Object.create(Ls),Ns=e=>Object.getPrototypeOf(e)===Ls;function ku(e,t,n,o=!1){const i={},r=js();e.propsDefaults=Object.create(null),Vs(e,t,i,r);for(const s in e.propsOptions[0])s in i||(i[s]=void 0);n?e.props=o?i:Ac(i):e.type.props?e.props=i:e.props=r,e.attrs=r}function Cu(e,t,n,o){const{props:i,attrs:r,vnode:{patchFlag:s}}=e,l=_e(i),[a]=e.propsOptions;let u=!1;if((o||s>0)&&!(s&16)){if(s&8){const c=e.vnode.dynamicProps;for(let d=0;d<c.length;d++){let f=c[d];if(Lo(e.emitsOptions,f))continue;const p=t[f];if(a)if(Ce(r,f))p!==r[f]&&(r[f]=p,u=!0);else{const b=Fe(f);i[b]=Bi(a,l,b,p,e,!1)}else p!==r[f]&&(r[f]=p,u=!0)}}}else{Vs(e,t,i,r)&&(u=!0);let c;for(const d in l)(!t||!Ce(t,d)&&((c=et(d))===d||!Ce(t,c)))&&(a?n&&(n[d]!==void 0||n[c]!==void 0)&&(i[d]=Bi(a,l,d,void 0,e,!0)):delete i[d]);if(r!==l)for(const d in r)(!t||!Ce(t,d))&&(delete r[d],u=!0)}u&&Nt(e.attrs,"set","")}function Vs(e,t,n,o){const[i,r]=e.propsOptions;let s=!1,l;if(t)for(let a in t){if(zn(a))continue;const u=t[a];let c;i&&Ce(i,c=Fe(a))?!r||!r.includes(c)?n[c]=u:(l||(l={}))[c]=u:Lo(e.emitsOptions,a)||(!(a in o)||u!==o[a])&&(o[a]=u,s=!0)}if(r){const a=_e(n),u=l||me;for(let c=0;c<r.length;c++){const d=r[c];n[d]=Bi(i,a,d,u[d],e,!Ce(u,d))}}return s}function Bi(e,t,n,o,i,r){const s=e[n];if(s!=null){const l=Ce(s,"default");if(l&&o===void 0){const a=s.default;if(s.type!==Function&&!s.skipFactory&&he(a)){const{propsDefaults:u}=i;if(n in u)o=u[n];else{const c=Gn(i);o=u[n]=a.call(null,t),c()}}else o=a;i.ce&&i.ce._setProp(n,o)}s[0]&&(r&&!l?o=!1:s[1]&&(o===""||o===et(n))&&(o=!0))}return o}const Tu=new WeakMap;function Rs(e,t,n=!1){const o=n?Tu:t.propsCache,i=o.get(e);if(i)return i;const r=e.props,s={},l=[];let a=!1;if(!he(e)){const c=d=>{a=!0;const[f,p]=Rs(d,t,!0);$e(s,f),p&&l.push(...p)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!a)return Ie(e)&&o.set(e,bt),bt;if(le(r))for(let c=0;c<r.length;c++){const d=Fe(r[c]);Hs(d)&&(s[d]=me)}else if(r)for(const c in r){const d=Fe(c);if(Hs(d)){const f=r[c],p=s[d]=le(f)||he(f)?{type:f}:$e({},f),b=p.type;let y=!1,$=!0;if(le(b))for(let k=0;k<b.length;++k){const B=b[k],F=he(B)&&B.name;if(F==="Boolean"){y=!0;break}else F==="String"&&($=!1)}else y=he(b)&&b.name==="Boolean";p[0]=y,p[1]=$,(y||Ce(p,"default"))&&l.push(d)}}const u=[s,l];return Ie(e)&&o.set(e,u),u}function Hs(e){return e[0]!=="$"&&!zn(e)}const Li=e=>e==="_"||e==="_ctx"||e==="$stable",ji=e=>le(e)?e.map(Mt):[Mt(e)],Pu=(e,t,n)=>{if(t._n)return t;const o=oe((...i)=>ji(t(...i)),n);return o._c=!1,o},Fs=(e,t,n)=>{const o=e._ctx;for(const i in e){if(Li(i))continue;const r=e[i];if(he(r))t[i]=Pu(i,r,o);else if(r!=null){const s=ji(r);t[i]=()=>s}}},Ws=(e,t)=>{const n=ji(t);e.slots.default=()=>n},qs=(e,t,n)=>{for(const o in t)(n||!Li(o))&&(e[o]=t[o])},Iu=(e,t,n)=>{const o=e.slots=js();if(e.vnode.shapeFlag&32){const i=t._;i?(qs(o,t,n),n&&Ar(o,"_",i,!0)):Fs(t,o)}else t&&Ws(e,t)},Eu=(e,t,n)=>{const{vnode:o,slots:i}=e;let r=!0,s=me;if(o.shapeFlag&32){const l=t._;l?n&&l===1?r=!1:qs(i,t,n):(r=!t.$stable,Fs(t,i)),s=t}else t&&(Ws(e,t),s={default:1});if(r)for(const l in i)!Li(l)&&s[l]==null&&delete i[l]},st=Wu;function Mu(e){return Ou(e)}function Ou(e,t){const n=ho();n.__VUE__=!0;const{insert:o,remove:i,patchProp:r,createElement:s,createText:l,createComment:a,setText:u,setElementText:c,parentNode:d,nextSibling:f,setScopeId:p=Ct,insertStaticContent:b}=e,y=(h,m,E,q=null,N=null,H=null,O=void 0,S=null,V=!!m.dynamicChildren)=>{if(h===m)return;h&&!dn(h,m)&&(q=xe(h),R(h,N,H,!0),h=null),m.patchFlag===-2&&(V=!1,m.dynamicChildren=null);const{type:L,ref:ce,shapeFlag:te}=m;switch(L){case jo:$(h,m,E,q);break;case Ke:k(h,m,E,q);break;case No:h==null&&B(m,E,q,O);break;case we:A(h,m,E,q,N,H,O,S,V);break;default:te&1?g(h,m,E,q,N,H,O,S,V):te&6?X(h,m,E,q,N,H,O,S,V):(te&64||te&128)&&L.process(h,m,E,q,N,H,O,S,V,Ae)}ce!=null&&N?Wn(ce,h&&h.ref,H,m||h,!m):ce==null&&h&&h.ref!=null&&Wn(h.ref,null,H,h,!0)},$=(h,m,E,q)=>{if(h==null)o(m.el=l(m.children),E,q);else{const N=m.el=h.el;m.children!==h.children&&u(N,m.children)}},k=(h,m,E,q)=>{h==null?o(m.el=a(m.children||""),E,q):m.el=h.el},B=(h,m,E,q)=>{[h.el,h.anchor]=b(h.children,m,E,q,h.el,h.anchor)},F=({el:h,anchor:m},E,q)=>{let N;for(;h&&h!==m;)N=f(h),o(h,E,q),h=N;o(m,E,q)},C=({el:h,anchor:m})=>{let E;for(;h&&h!==m;)E=f(h),i(h),h=E;i(m)},g=(h,m,E,q,N,H,O,S,V)=>{if(m.type==="svg"?O="svg":m.type==="math"&&(O="mathml"),h==null)T(m,E,q,N,H,O,S,V);else{const L=h.el&&h.el._isVueCE?h.el:null;try{L&&L._beginPatch(),w(h,m,N,H,O,S,V)}finally{L&&L._endPatch()}}},T=(h,m,E,q,N,H,O,S)=>{let V,L;const{props:ce,shapeFlag:te,transition:J,dirs:ue}=h;if(V=h.el=s(h.type,H,ce&&ce.is,ce),te&8?c(V,h.children):te&16&&z(h.children,V,null,q,N,Ni(h,H),O,S),ue&&an(h,null,q,"created"),x(V,h,h.scopeId,O,q),ce){for(const Oe in ce)Oe!=="value"&&!zn(Oe)&&r(V,Oe,null,ce[Oe],H,q);"value"in ce&&r(V,"value",null,ce.value,H),(L=ce.onVnodeBeforeMount)&&Ot(L,q,h)}ue&&an(h,null,q,"beforeMount");const Se=$u(N,J);Se&&J.beforeEnter(V),o(V,m,E),((L=ce&&ce.onVnodeMounted)||Se||ue)&&st(()=>{L&&Ot(L,q,h),Se&&J.enter(V),ue&&an(h,null,q,"mounted")},N)},x=(h,m,E,q,N)=>{if(E&&p(h,E),q)for(let H=0;H<q.length;H++)p(h,q[H]);if(N){let H=N.subTree;if(m===H||tl(H.type)&&(H.ssContent===m||H.ssFallback===m)){const O=N.vnode;x(h,O,O.scopeId,O.slotScopeIds,N.parent)}}},z=(h,m,E,q,N,H,O,S,V=0)=>{for(let L=V;L<h.length;L++){const ce=h[L]=S?Qt(h[L]):Mt(h[L]);y(null,ce,m,E,q,N,H,O,S)}},w=(h,m,E,q,N,H,O)=>{const S=m.el=h.el;let{patchFlag:V,dynamicChildren:L,dirs:ce}=m;V|=h.patchFlag&16;const te=h.props||me,J=m.props||me;let ue;if(E&&un(E,!1),(ue=J.onVnodeBeforeUpdate)&&Ot(ue,E,m,h),ce&&an(m,h,E,"beforeUpdate"),E&&un(E,!0),(te.innerHTML&&J.innerHTML==null||te.textContent&&J.textContent==null)&&c(S,""),L?M(h.dynamicChildren,L,S,E,q,Ni(m,N),H):O||_(h,m,S,null,E,q,Ni(m,N),H,!1),V>0){if(V&16)W(S,te,J,E,N);else if(V&2&&te.class!==J.class&&r(S,"class",null,J.class,N),V&4&&r(S,"style",te.style,J.style,N),V&8){const Se=m.dynamicProps;for(let Oe=0;Oe<Se.length;Oe++){const Ee=Se[Oe],ot=te[Ee],it=J[Ee];(it!==ot||Ee==="value")&&r(S,Ee,ot,it,N,E)}}V&1&&h.children!==m.children&&c(S,m.children)}else!O&&L==null&&W(S,te,J,E,N);((ue=J.onVnodeUpdated)||ce)&&st(()=>{ue&&Ot(ue,E,m,h),ce&&an(m,h,E,"updated")},q)},M=(h,m,E,q,N,H,O)=>{for(let S=0;S<m.length;S++){const V=h[S],L=m[S],ce=V.el&&(V.type===we||!dn(V,L)||V.shapeFlag&198)?d(V.el):E;y(V,L,ce,null,q,N,H,O,!0)}},W=(h,m,E,q,N)=>{if(m!==E){if(m!==me)for(const H in m)!zn(H)&&!(H in E)&&r(h,H,m[H],null,N,q);for(const H in E){if(zn(H))continue;const O=E[H],S=m[H];O!==S&&H!=="value"&&r(h,H,S,O,N,q)}"value"in E&&r(h,"value",m.value,E.value,N)}},A=(h,m,E,q,N,H,O,S,V)=>{const L=m.el=h?h.el:l(""),ce=m.anchor=h?h.anchor:l("");let{patchFlag:te,dynamicChildren:J,slotScopeIds:ue}=m;ue&&(S=S?S.concat(ue):ue),h==null?(o(L,E,q),o(ce,E,q),z(m.children||[],E,ce,N,H,O,S,V)):te>0&&te&64&&J&&h.dynamicChildren?(M(h.dynamicChildren,J,E,N,H,O,S),(m.key!=null||N&&m===N.subTree)&&Us(h,m,!0)):_(h,m,E,ce,N,H,O,S,V)},X=(h,m,E,q,N,H,O,S,V)=>{m.slotScopeIds=S,h==null?m.shapeFlag&512?N.ctx.activate(m,E,q,O,V):I(m,E,q,N,H,O,V):ne(h,m,V)},I=(h,m,E,q,N,H,O)=>{const S=h.component=Gu(h,q,N);if($o(h)&&(S.ctx.renderer=Ae),Ju(S,!1,O),S.asyncDep){if(N&&N.registerDep(S,G,O),!h.el){const V=S.subTree=j(Ke);k(null,V,m,E),h.placeholder=V.el}}else G(S,h,m,E,N,H,O)},ne=(h,m,E)=>{const q=m.component=h.component;if(Hu(h,m,E))if(q.asyncDep&&!q.asyncResolved){P(q,m,E);return}else q.next=m,q.update();else m.el=h.el,q.vnode=m},G=(h,m,E,q,N,H,O)=>{const S=()=>{if(h.isMounted){let{next:te,bu:J,u:ue,parent:Se,vnode:Oe}=h;{const Lt=Ks(h);if(Lt){te&&(te.el=Oe.el,P(h,te,O)),Lt.asyncDep.then(()=>{h.isUnmounted||S()});return}}let Ee=te,ot;un(h,!1),te?(te.el=Oe.el,P(h,te,O)):te=Oe,J&&po(J),(ot=te.props&&te.props.onVnodeBeforeUpdate)&&Ot(ot,Se,te,Oe),un(h,!0);const it=Qs(h),Bt=h.subTree;h.subTree=it,y(Bt,it,d(Bt.el),xe(Bt),h,N,H),te.el=it.el,Ee===null&&Fu(h,it.el),ue&&st(ue,N),(ot=te.props&&te.props.onVnodeUpdated)&&st(()=>Ot(ot,Se,te,Oe),N)}else{let te;const{el:J,props:ue}=m,{bm:Se,m:Oe,parent:Ee,root:ot,type:it}=h,Bt=Pn(m);un(h,!1),Se&&po(Se),!Bt&&(te=ue&&ue.onVnodeBeforeMount)&&Ot(te,Ee,m),un(h,!0);{ot.ce&&ot.ce._def.shadowRoot!==!1&&ot.ce._injectChildStyle(it);const Lt=h.subTree=Qs(h);y(null,Lt,E,q,h,N,H),m.el=Lt.el}if(Oe&&st(Oe,N),!Bt&&(te=ue&&ue.onVnodeMounted)){const Lt=m;st(()=>Ot(te,Ee,Lt),N)}(m.shapeFlag&256||Ee&&Pn(Ee.vnode)&&Ee.vnode.shapeFlag&256)&&h.a&&st(h.a,N),h.isMounted=!0,m=E=q=null}};h.scope.on();const V=h.effect=new Rr(S);h.scope.off();const L=h.update=V.run.bind(V),ce=h.job=V.runIfDirty.bind(V);ce.i=h,ce.id=h.uid,V.scheduler=()=>Pi(ce),un(h,!0),L()},P=(h,m,E)=>{m.component=h;const q=h.vnode.props;h.vnode=m,h.next=null,Cu(h,m.props,q,E),Eu(h,m.children,E),Tt(),ds(h),Pt()},_=(h,m,E,q,N,H,O,S,V=!1)=>{const L=h&&h.children,ce=h?h.shapeFlag:0,te=m.children,{patchFlag:J,shapeFlag:ue}=m;if(J>0){if(J&128){se(L,te,E,q,N,H,O,S,V);return}else if(J&256){Y(L,te,E,q,N,H,O,S,V);return}}ue&8?(ce&16&&ve(L,N,H),te!==L&&c(E,te)):ce&16?ue&16?se(L,te,E,q,N,H,O,S,V):ve(L,N,H,!0):(ce&8&&c(E,""),ue&16&&z(te,E,q,N,H,O,S,V))},Y=(h,m,E,q,N,H,O,S,V)=>{h=h||bt,m=m||bt;const L=h.length,ce=m.length,te=Math.min(L,ce);let J;for(J=0;J<te;J++){const ue=m[J]=V?Qt(m[J]):Mt(m[J]);y(h[J],ue,E,null,N,H,O,S,V)}L>ce?ve(h,N,H,!0,!1,te):z(m,E,q,N,H,O,S,V,te)},se=(h,m,E,q,N,H,O,S,V)=>{let L=0;const ce=m.length;let te=h.length-1,J=ce-1;for(;L<=te&&L<=J;){const ue=h[L],Se=m[L]=V?Qt(m[L]):Mt(m[L]);if(dn(ue,Se))y(ue,Se,E,null,N,H,O,S,V);else break;L++}for(;L<=te&&L<=J;){const ue=h[te],Se=m[J]=V?Qt(m[J]):Mt(m[J]);if(dn(ue,Se))y(ue,Se,E,null,N,H,O,S,V);else break;te--,J--}if(L>te){if(L<=J){const ue=J+1,Se=ue<ce?m[ue].el:q;for(;L<=J;)y(null,m[L]=V?Qt(m[L]):Mt(m[L]),E,Se,N,H,O,S,V),L++}}else if(L>J)for(;L<=te;)R(h[L],N,H,!0),L++;else{const ue=L,Se=L,Oe=new Map;for(L=Se;L<=J;L++){const ct=m[L]=V?Qt(m[L]):Mt(m[L]);ct.key!=null&&Oe.set(ct.key,L)}let Ee,ot=0;const it=J-Se+1;let Bt=!1,Lt=0;const so=new Array(it);for(L=0;L<it;L++)so[L]=0;for(L=ue;L<=te;L++){const ct=h[L];if(ot>=it){R(ct,N,H,!0);continue}let jt;if(ct.key!=null)jt=Oe.get(ct.key);else for(Ee=Se;Ee<=J;Ee++)if(so[Ee-Se]===0&&dn(ct,m[Ee])){jt=Ee;break}jt===void 0?R(ct,N,H,!0):(so[jt-Se]=L+1,jt>=Lt?Lt=jt:Bt=!0,y(ct,m[jt],E,null,N,H,O,S,V),ot++)}const tc=Bt?Du(so):bt;for(Ee=tc.length-1,L=it-1;L>=0;L--){const ct=Se+L,jt=m[ct],nc=m[ct+1],oc=ct+1<ce?nc.el||nc.placeholder:q;so[L]===0?y(null,jt,E,oc,N,H,O,S,V):Bt&&(Ee<0||L!==tc[Ee]?K(jt,E,oc,2):Ee--)}}},K=(h,m,E,q,N=null)=>{const{el:H,type:O,transition:S,children:V,shapeFlag:L}=h;if(L&6){K(h.component.subTree,m,E,q);return}if(L&128){h.suspense.move(m,E,q);return}if(L&64){O.move(h,m,E,Ae);return}if(O===we){o(H,m,E);for(let te=0;te<V.length;te++)K(V[te],m,E,q);o(h.anchor,m,E);return}if(O===No){F(h,m,E);return}if(q!==2&&L&1&&S)if(q===0)S.beforeEnter(H),o(H,m,E),st(()=>S.enter(H),N);else{const{leave:te,delayLeave:J,afterLeave:ue}=S,Se=()=>{h.ctx.isUnmounted?i(H):o(H,m,E)},Oe=()=>{H._isLeaving&&H[Ht](!0),te(H,()=>{Se(),ue&&ue()})};J?J(H,Se,Oe):Oe()}else o(H,m,E)},R=(h,m,E,q=!1,N=!1)=>{const{type:H,props:O,ref:S,children:V,dynamicChildren:L,shapeFlag:ce,patchFlag:te,dirs:J,cacheIndex:ue}=h;if(te===-2&&(N=!1),S!=null&&(Tt(),Wn(S,null,E,h,!0),Pt()),ue!=null&&(m.renderCache[ue]=void 0),ce&256){m.ctx.deactivate(h);return}const Se=ce&1&&J,Oe=!Pn(h);let Ee;if(Oe&&(Ee=O&&O.onVnodeBeforeUnmount)&&Ot(Ee,m,h),ce&6)pe(h.component,E,q);else{if(ce&128){h.suspense.unmount(E,q);return}Se&&an(h,null,m,"beforeUnmount"),ce&64?h.type.remove(h,m,E,Ae,q):L&&!L.hasOnce&&(H!==we||te>0&&te&64)?ve(L,m,E,!1,!0):(H===we&&te&384||!N&&ce&16)&&ve(V,m,E),q&&Pe(h)}(Oe&&(Ee=O&&O.onVnodeUnmounted)||Se)&&st(()=>{Ee&&Ot(Ee,m,h),Se&&an(h,null,m,"unmounted")},E)},Pe=h=>{const{type:m,el:E,anchor:q,transition:N}=h;if(m===we){ye(E,q);return}if(m===No){C(h);return}const H=()=>{i(E),N&&!N.persisted&&N.afterLeave&&N.afterLeave()};if(h.shapeFlag&1&&N&&!N.persisted){const{leave:O,delayLeave:S}=N,V=()=>O(E,H);S?S(h.el,H,V):V()}else H()},ye=(h,m)=>{let E;for(;h!==m;)E=f(h),i(h),h=E;i(m)},pe=(h,m,E)=>{const{bum:q,scope:N,job:H,subTree:O,um:S,m:V,a:L}=h;Zs(V),Zs(L),q&&po(q),N.stop(),H&&(H.flags|=8,R(O,h,m,E)),S&&st(S,m),st(()=>{h.isUnmounted=!0},m)},ve=(h,m,E,q=!1,N=!1,H=0)=>{for(let O=H;O<h.length;O++)R(h[O],m,E,q,N)},xe=h=>{if(h.shapeFlag&6)return xe(h.component.subTree);if(h.shapeFlag&128)return h.suspense.next();const m=f(h.anchor||h.el),E=m&&m[tu];return E?f(E):m};let Be=!1;const Qe=(h,m,E)=>{h==null?m._vnode&&R(m._vnode,null,null,!0):y(m._vnode||null,h,m,null,null,null,E),m._vnode=h,Be||(Be=!0,ds(),fs(),Be=!1)},Ae={p:y,um:R,m:K,r:Pe,mt:I,mc:z,pc:_,pbc:M,n:xe,o:e};return{render:Qe,hydrate:void 0,createApp:Su(Qe)}}function Ni({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 un({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function $u(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Us(e,t,n=!1){const o=e.children,i=t.children;if(le(o)&&le(i))for(let r=0;r<o.length;r++){const s=o[r];let l=i[r];l.shapeFlag&1&&!l.dynamicChildren&&((l.patchFlag<=0||l.patchFlag===32)&&(l=i[r]=Qt(i[r]),l.el=s.el),!n&&l.patchFlag!==-2&&Us(s,l)),l.type===jo&&l.patchFlag!==-1&&(l.el=s.el),l.type===Ke&&!l.el&&(l.el=s.el)}}function Du(e){const t=e.slice(),n=[0];let o,i,r,s,l;const a=e.length;for(o=0;o<a;o++){const u=e[o];if(u!==0){if(i=n[n.length-1],e[i]<u){t[o]=i,n.push(o);continue}for(r=0,s=n.length-1;r<s;)l=r+s>>1,e[n[l]]<u?r=l+1:s=l;u<e[n[r]]&&(r>0&&(t[o]=n[r-1]),n[r]=o)}}for(r=n.length,s=n[r-1];r-- >0;)n[r]=s,s=t[s];return n}function Ks(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Ks(t)}function Zs(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const zu=Symbol.for("v-scx"),Au=()=>Wt(zu);function Ys(e,t){return Bo(e,null,t)}function Bu(e,t){return Bo(e,null,{flush:"sync"})}function fe(e,t,n){return Bo(e,t,n)}function Bo(e,t,n=me){const{immediate:o,deep:i,flush:r,once:s}=n,l=$e({},n),a=t&&o||!t&&r!=="post";let u;if(Jn){if(r==="sync"){const p=Au();u=p.__watcherHandles||(p.__watcherHandles=[])}else if(!a){const p=()=>{};return p.stop=Ct,p.resume=Ct,p.pause=Ct,p}}const c=Ze;l.call=(p,b,y)=>xt(p,c,b,y);let d=!1;r==="post"?l.scheduler=p=>{st(p,c&&c.suspense)}:r!=="sync"&&(d=!0,l.scheduler=(p,b)=>{b?p():Pi(p)}),l.augmentJob=p=>{t&&(p.flags|=4),d&&(p.flags|=2,c&&(p.id=c.uid,p.i=c))};const f=Kc(e,t,l);return Jn&&(u?u.push(f):a&&f()),f}function Lu(e,t,n){const o=this.proxy,i=De(e)?e.includes(".")?Xs(o,e):()=>o[e]:e.bind(o,o);let r;he(t)?r=t:(r=t.handler,n=t);const s=Gn(this),l=Bo(i,r.bind(o),n);return s(),l}function Xs(e,t){const n=t.split(".");return()=>{let o=e;for(let i=0;i<n.length&&o;i++)o=o[n[i]];return o}}function lt(e,t,n=me){const o=fn(),i=Fe(t),r=et(t),s=Gs(e,i),l=ls((a,u)=>{let c,d=me,f;return Bu(()=>{const p=e[i];tt(c,p)&&(c=p,u())}),{get(){return a(),n.get?n.get(c):c},set(p){const b=n.set?n.set(p):p;if(!tt(b,c)&&!(d!==me&&tt(p,d)))return;const y=o.vnode.props;y&&(t in y||i in y||r in y)&&(`onUpdate:${t}`in y||`onUpdate:${i}`in y||`onUpdate:${r}`in y)||(c=p,u()),o.emit(`update:${t}`,b),tt(p,b)&&tt(p,d)&&!tt(b,f)&&u(),d=p,f=b}}});return l[Symbol.iterator]=()=>{let a=0;return{next(){return a<2?{value:a++?s||me:l,done:!1}:{done:!0}}}},l}const Gs=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Fe(t)}Modifiers`]||e[`${et(t)}Modifiers`];function ju(e,t,...n){if(e.isUnmounted)return;const o=e.vnode.props||me;let i=n;const r=t.startsWith("update:"),s=r&&Gs(o,t.slice(7));s&&(s.trim&&(i=n.map(c=>De(c)?c.trim():c)),s.number&&(i=n.map(fi)));let l,a=o[l=di(t)]||o[l=di(Fe(t))];!a&&r&&(a=o[l=di(et(t))]),a&&xt(a,e,6,i);const u=o[l+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,xt(u,e,6,i)}}const Nu=new WeakMap;function Js(e,t,n=!1){const o=n?Nu:t.emitsCache,i=o.get(e);if(i!==void 0)return i;const r=e.emits;let s={},l=!1;if(!he(e)){const a=u=>{const c=Js(u,t,!0);c&&(l=!0,$e(s,c))};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}return!r&&!l?(Ie(e)&&o.set(e,null),null):(le(r)?r.forEach(a=>s[a]=null):$e(s,r),Ie(e)&&o.set(e,s),s)}function Lo(e,t){return!e||!lo(t)?!1:(t=t.slice(2).replace(/Once$/,""),Ce(e,t[0].toLowerCase()+t.slice(1))||Ce(e,et(t))||Ce(e,t))}function M0(){}function Qs(e){const{type:t,vnode:n,proxy:o,withProxy:i,propsOptions:[r],slots:s,attrs:l,emit:a,render:u,renderCache:c,props:d,data:f,setupState:p,ctx:b,inheritAttrs:y}=e,$=Eo(e);let k,B;try{if(n.shapeFlag&4){const C=i||o,g=C;k=Mt(u.call(g,C,c,d,p,f,b)),B=l}else{const C=t;k=Mt(C.length>1?C(d,{attrs:l,slots:s,emit:a}):C(d,null)),B=t.props?l:Vu(l)}}catch(C){Zn.length=0,Po(C,e,1),k=j(Ke)}let F=k;if(B&&y!==!1){const C=Object.keys(B),{shapeFlag:g}=F;C.length&&g&7&&(r&&C.some(ai)&&(B=Ru(B,r)),F=Jt(F,B,!1,!0))}return n.dirs&&(F=Jt(F,null,!1,!0),F.dirs=F.dirs?F.dirs.concat(n.dirs):n.dirs),n.transition&&Fn(F,n.transition),k=F,Eo($),k}const Vu=e=>{let t;for(const n in e)(n==="class"||n==="style"||lo(n))&&((t||(t={}))[n]=e[n]);return t},Ru=(e,t)=>{const n={};for(const o in e)(!ai(o)||!(o.slice(9)in t))&&(n[o]=e[o]);return n};function Hu(e,t,n){const{props:o,children:i,component:r}=e,{props:s,children:l,patchFlag:a}=t,u=r.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&a>=0){if(a&1024)return!0;if(a&16)return o?el(o,s,u):!!s;if(a&8){const c=t.dynamicProps;for(let d=0;d<c.length;d++){const f=c[d];if(s[f]!==o[f]&&!Lo(u,f))return!0}}}else return(i||l)&&(!l||!l.$stable)?!0:o===s?!1:o?s?el(o,s,u):!0:!!s;return!1}function el(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let i=0;i<o.length;i++){const r=o[i];if(t[r]!==e[r]&&!Lo(n,r))return!0}return!1}function Fu({vnode:e,parent:t},n){for(;t;){const o=t.subTree;if(o.suspense&&o.suspense.activeBranch===e&&(o.el=e.el),o===e)(e=t.vnode).el=n,t=t.parent;else break}}const tl=e=>e.__isSuspense;function Wu(e,t){t&&t.pendingBranch?le(e)?t.effects.push(...e):t.effects.push(e):eu(e)}const we=Symbol.for("v-fgt"),jo=Symbol.for("v-txt"),Ke=Symbol.for("v-cmt"),No=Symbol.for("v-stc"),Zn=[];let at=null;function v(e=!1){Zn.push(at=e?null:[])}function qu(){Zn.pop(),at=Zn[Zn.length-1]||null}let Yn=1;function Vo(e,t=!1){Yn+=e,e<0&&at&&t&&(at.hasOnce=!0)}function nl(e){return e.dynamicChildren=Yn>0?at||bt:null,qu(),Yn>0&&at&&at.push(e),e}function D(e,t,n,o,i,r){return nl(U(e,t,n,o,i,r,!0))}function re(e,t,n,o,i){return nl(j(e,t,n,o,i,!0))}function Xn(e){return e?e.__v_isVNode===!0:!1}function dn(e,t){return e.type===t.type&&e.key===t.key}const ol=({key:e})=>e??null,Ro=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?De(e)||ze(e)||he(e)?{i:Re,r:e,k:t,f:!!n}:e:null);function U(e,t=null,n=null,o=0,i=null,r=e===we?0:1,s=!1,l=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&ol(t),ref:t&&Ro(t),scopeId:hs,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:r,patchFlag:o,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Re};return l?(Vi(a,n),r&128&&e.normalize(a)):n&&(a.shapeFlag|=De(n)?8:16),Yn>0&&!s&&at&&(a.patchFlag>0||r&6)&&a.patchFlag!==32&&at.push(a),a}const j=Uu;function Uu(e,t=null,n=null,o=0,i=null,r=!1){if((!e||e===Ts)&&(e=Ke),Xn(e)){const l=Jt(e,t,!0);return n&&Vi(l,n),Yn>0&&!r&&at&&(l.shapeFlag&6?at[at.indexOf(e)]=l:at.push(l)),l.patchFlag=-2,l}if(id(e)&&(e=e.__vccOpts),t){t=Ku(t);let{class:l,style:a}=t;l&&!De(l)&&(t.class=de(l)),Ie(a)&&(Ci(a)&&!le(a)&&(a=$e({},a)),t.style=Te(a))}const s=De(e)?1:tl(e)?128:gs(e)?64:Ie(e)?4:he(e)?2:0;return U(e,t,n,o,i,s,r,!0)}function Ku(e){return e?Ci(e)||Ns(e)?$e({},e):e:null}function Jt(e,t,n=!1,o=!1){const{props:i,ref:r,patchFlag:s,children:l,transition:a}=e,u=t?In(i||{},t):i,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&ol(u),ref:t&&t.ref?n&&r?le(r)?r.concat(Ro(t)):[r,Ro(t)]:Ro(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==we?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:a,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Jt(e.ssContent),ssFallback:e.ssFallback&&Jt(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return a&&o&&Fn(c,a.clone(c)),c}function qt(e=" ",t=0){return j(jo,null,e,t)}function Zu(e,t){const n=j(No,null,e);return n.staticCount=t,n}function ae(e="",t=!1){return t?(v(),re(Ke,null,e)):j(Ke,null,e)}function Mt(e){return e==null||typeof e=="boolean"?j(Ke):le(e)?j(we,null,e.slice()):Xn(e)?Qt(e):j(jo,null,String(e))}function Qt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Jt(e)}function Vi(e,t){let n=0;const{shapeFlag:o}=e;if(t==null)t=null;else if(le(t))n=16;else if(typeof t=="object")if(o&65){const i=t.default;i&&(i._c&&(i._d=!1),Vi(e,i()),i._c&&(i._d=!0));return}else{n=32;const i=t._;!i&&!Ns(t)?t._ctx=Re:i===3&&Re&&(Re.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else he(t)?(t={default:t,_ctx:Re},n=32):(t=String(t),o&64?(n=16,t=[qt(t)]):n=8);e.children=t,e.shapeFlag|=n}function In(...e){const t={};for(let n=0;n<e.length;n++){const o=e[n];for(const i in o)if(i==="class")t.class!==o.class&&(t.class=de([t.class,o.class]));else if(i==="style")t.style=Te([t.style,o.style]);else if(lo(i)){const r=t[i],s=o[i];s&&r!==s&&!(le(r)&&r.includes(s))&&(t[i]=r?[].concat(r,s):s)}else i!==""&&(t[i]=o[i])}return t}function Ot(e,t,n,o=null){xt(e,t,7,[n,o])}const Yu=As();let Xu=0;function Gu(e,t,n){const o=e.type,i=(t?t.appContext:e.appContext)||Yu,r={uid:Xu++,vnode:e,type:o,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new hc(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Rs(o,i),emitsOptions:Js(o,i),emit:null,emitted:null,propsDefaults:me,inheritAttrs:o.inheritAttrs,ctx:me,data:me,props:me,attrs:me,slots:me,refs:me,setupState:me,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 r.ctx={_:r},r.root=t?t.root:r,r.emit=ju.bind(null,r),e.ce&&e.ce(r),r}let Ze=null;const fn=()=>Ze||Re;let Ho,Ri;{const e=ho(),t=(n,o)=>{let i;return(i=e[n])||(i=e[n]=[]),i.push(o),r=>{i.length>1?i.forEach(s=>s(r)):i[0](r)}};Ho=t("__VUE_INSTANCE_SETTERS__",n=>Ze=n),Ri=t("__VUE_SSR_SETTERS__",n=>Jn=n)}const Gn=e=>{const t=Ze;return Ho(e),e.scope.on(),()=>{e.scope.off(),Ho(t)}},il=()=>{Ze&&Ze.scope.off(),Ho(null)};function rl(e){return e.vnode.shapeFlag&4}let Jn=!1;function Ju(e,t=!1,n=!1){t&&Ri(t);const{props:o,children:i}=e.vnode,r=rl(e);ku(e,o,r,t),Iu(e,i,n||t);const s=r?Qu(e,t):void 0;return t&&Ri(!1),s}function Qu(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,mu);const{setup:o}=n;if(o){Tt();const i=e.setupContext=o.length>1?td(e):null,r=Gn(e),s=kn(o,e,0,[e.props,i]),l=Dr(s);if(Pt(),r(),(l||e.sp)&&!Pn(e)&&_s(e),l){if(s.then(il,il),t)return s.then(a=>{sl(e,a)}).catch(a=>{Po(a,e,0)});e.asyncDep=s}else sl(e,s)}else ll(e)}function sl(e,t,n){he(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ie(t)&&(e.setupState=ss(t)),ll(e)}function ll(e,t,n){const o=e.type;e.render||(e.render=o.render||Ct);{const i=Gn(e);Tt();try{vu(e)}finally{Pt(),i()}}}const ed={get(e,t){return Ue(e,"get",""),e[t]}};function td(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,ed),slots:e.slots,emit:e.emit,expose:t}}function Fo(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(ss(Bc(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in qn)return qn[n](e)},has(t,n){return n in t||n in qn}})):e.proxy}const nd=/(?:^|[-_])\w/g,od=e=>e.replace(nd,t=>t.toUpperCase()).replace(/[-_]/g,"");function al(e,t=!0){return he(e)?e.displayName||e.name:e.name||t&&e.__name}function cl(e,t,n=!1){let o=al(t);if(!o&&t.__file){const i=t.__file.match(/([^/\\]+)\.\w+$/);i&&(o=i[1])}if(!o&&e&&e.parent){const i=r=>{for(const s in r)if(r[s]===t)return s};o=i(e.components||e.parent.type.components)||i(e.appContext.components)}return o?od(o):n?"App":"Anonymous"}function id(e){return he(e)&&"__vccOpts"in e}const Q=(e,t)=>qc(e,t,Jn);function ul(e,t,n){try{Vo(-1);const o=arguments.length;return o===2?Ie(t)&&!le(t)?Xn(t)?j(e,null,[t]):j(e,t):j(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):o===3&&Xn(n)&&(n=[n]),j(e,t,n))}finally{Vo(1)}}const rd="3.5.24";/**
|
|
17
17
|
* @vue/runtime-dom v3.5.24
|
|
18
18
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
19
19
|
* @license MIT
|
|
20
|
-
**/let Vi;const rl=typeof window<"u"&&window.trustedTypes;if(rl)try{Vi=rl.createPolicy("vue",{createHTML:e=>e})}catch{}const sl=Vi?e=>Vi.createHTML(e):e=>e,Ku="http://www.w3.org/2000/svg",Zu="http://www.w3.org/1998/Math/MathML",Ut=typeof document<"u"?document:null,ll=Ut&&Ut.createElement("template"),Yu={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const i=t==="svg"?Ut.createElementNS(Ku,e):t==="mathml"?Ut.createElementNS(Zu,e):n?Ut.createElement(e,{is:n}):Ut.createElement(e);return e==="select"&&o&&o.multiple!=null&&i.setAttribute("multiple",o.multiple),i},createText:e=>Ut.createTextNode(e),createComment:e=>Ut.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ut.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,o,i,r){const s=n?n.previousSibling:t.lastChild;if(i&&(i===r||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===r||!(i=i.nextSibling)););else{ll.innerHTML=sl(o==="svg"?`<svg>${e}</svg>`:o==="mathml"?`<math>${e}</math>`:e);const l=ll.content;if(o==="svg"||o==="mathml"){const a=l.firstChild;for(;a.firstChild;)l.appendChild(a.firstChild);l.removeChild(a)}t.insertBefore(l,n)}return[s?s.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Qt="transition",Yn="animation",Xn=Symbol("_vtc"),al={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},Xu=Oe({},us,al),Gn=(e=>(e.displayName="Transition",e.props=Xu,e))((e,{slots:t})=>il(Uc,Gu(e),t)),fn=(e,t=[])=>{re(e)?e.forEach(n=>n(...t)):e&&e(...t)},cl=e=>e?re(e)?e.some(t=>t.length>1):e.length>1:!1;function Gu(e){const t={};for(const M in e)M in al||(t[M]=e[M]);if(e.css===!1)return t;const{name:n="v",type:o,duration:i,enterFromClass:r=`${n}-enter-from`,enterActiveClass:s=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:a=r,appearActiveClass:u=s,appearToClass:c=l,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:h=`${n}-leave-to`}=e,w=Ju(i),y=w&&w[0],$=w&&w[1],{onBeforeEnter:k,onEnter:B,onEnterCancelled:A,onLeave:b,onLeaveCancelled:g,onBeforeAppear:E=k,onAppear:L=B,onAppearCancelled:Z=A}=t,_=(M,G,C,ee)=>{M._enterCancelled=ee,pn(M,G?c:l),pn(M,G?u:s),C&&C()},O=(M,G)=>{M._isLeaving=!1,pn(M,d),pn(M,h),pn(M,f),G&&G()},j=M=>(G,C)=>{const ee=M?L:B,W=()=>_(G,M,C);fn(ee,[G,W]),ul(()=>{pn(G,M?a:r),qt(G,M?c:l),cl(ee)||dl(G,o,y,W)})};return Oe(t,{onBeforeEnter(M){fn(k,[M]),qt(M,r),qt(M,s)},onBeforeAppear(M){fn(E,[M]),qt(M,a),qt(M,u)},onEnter:j(!1),onAppear:j(!0),onLeave(M,G){M._isLeaving=!0;const C=()=>O(M,G);qt(M,d),M._enterCancelled?(qt(M,f),hl(M)):(hl(M),qt(M,f)),ul(()=>{M._isLeaving&&(pn(M,d),qt(M,h),cl(b)||dl(M,o,$,C))}),fn(b,[M,C])},onEnterCancelled(M){_(M,!1,void 0,!0),fn(A,[M])},onAppearCancelled(M){_(M,!0,void 0,!0),fn(Z,[M])},onLeaveCancelled(M){O(M),fn(g,[M])}})}function Ju(e){if(e==null)return null;if(Te(e))return[Ri(e.enter),Ri(e.leave)];{const t=Ri(e);return[t,t]}}function Ri(e){return di(e)}function qt(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Xn]||(e[Xn]=new Set)).add(t)}function pn(e,t){t.split(/\s+/).forEach(o=>o&&e.classList.remove(o));const n=e[Xn];n&&(n.delete(t),n.size||(e[Xn]=void 0))}function ul(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let Qu=0;function dl(e,t,n,o){const i=e._endId=++Qu,r=()=>{i===e._endId&&o()};if(n!=null)return setTimeout(r,n);const{type:s,timeout:l,propCount:a}=ed(e,t);if(!s)return o();const u=s+"end";let c=0;const d=()=>{e.removeEventListener(u,f),r()},f=h=>{h.target===e&&++c>=a&&d()};setTimeout(()=>{c<a&&d()},l+1),e.addEventListener(u,f)}function ed(e,t){const n=window.getComputedStyle(e),o=w=>(n[w]||"").split(", "),i=o(`${Qt}Delay`),r=o(`${Qt}Duration`),s=fl(i,r),l=o(`${Yn}Delay`),a=o(`${Yn}Duration`),u=fl(l,a);let c=null,d=0,f=0;t===Qt?s>0&&(c=Qt,d=s,f=r.length):t===Yn?u>0&&(c=Yn,d=u,f=a.length):(d=Math.max(s,u),c=d>0?s>u?Qt:Yn:null,f=c?c===Qt?r.length:a.length:0);const h=c===Qt&&/\b(?:transform|all)(?:,|$)/.test(o(`${Qt}Property`).toString());return{type:c,timeout:d,propCount:f,hasTransform:h}}function fl(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,o)=>pl(n)+pl(e[o])))}function pl(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function hl(e){return(e?e.ownerDocument:document).body.offsetHeight}function td(e,t,n){const o=e[Xn];o&&(t=(t?[t,...o]:[...o]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Fo=Symbol("_vod"),gl=Symbol("_vsh"),nd={name:"show",beforeMount(e,{value:t},{transition:n}){e[Fo]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Jn(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),Jn(e,!0),o.enter(e)):o.leave(e,()=>{Jn(e,!1)}):Jn(e,t))},beforeUnmount(e,{value:t}){Jn(e,t)}};function Jn(e,t){e.style.display=t?e[Fo]:"none",e[gl]=!t}const od=Symbol(""),id=/(?:^|;)\s*display\s*:/;function rd(e,t,n){const o=e.style,i=$e(n);let r=!1;if(n&&!i){if(t)if($e(t))for(const s of t.split(";")){const l=s.slice(0,s.indexOf(":")).trim();n[l]==null&&Wo(o,l,"")}else for(const s in t)n[s]==null&&Wo(o,s,"");for(const s in n)s==="display"&&(r=!0),Wo(o,s,n[s])}else if(i){if(t!==n){const s=o[od];s&&(n+=";"+s),o.cssText=n,r=id.test(n)}}else t&&e.removeAttribute("style");Fo in e&&(e[Fo]=r?o.display:"",e[gl]&&(o.display="none"))}const ml=/\s*!important$/;function Wo(e,t,n){if(re(n))n.forEach(o=>Wo(e,t,o));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const o=sd(e,t);ml.test(n)?e.setProperty(Qe(o),n.replace(ml,""),"important"):e[o]=n}}const vl=["Webkit","Moz","ms"],Hi={};function sd(e,t){const n=Hi[t];if(n)return n;let o=He(t);if(o!=="filter"&&o in e)return Hi[t]=o;o=uo(o);for(let i=0;i<vl.length;i++){const r=vl[i]+o;if(r in e)return Hi[t]=r}return t}const bl="http://www.w3.org/1999/xlink";function yl(e,t,n,o,i,r=Qa(t)){o&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(bl,t.slice(6,t.length)):e.setAttributeNS(bl,t,n):n==null||r&&!Or(n)?e.removeAttribute(t):e.setAttribute(t,r?"":bt(n)?String(n):n)}function wl(e,t,n,o,i){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?sl(n):n);return}const r=e.tagName;if(t==="value"&&r!=="PROGRESS"&&!r.includes("-")){const l=r==="OPTION"?e.getAttribute("value")||"":e.value,a=n==null?e.type==="checkbox"?"on":"":String(n);(l!==a||!("_value"in e))&&(e.value=a),n==null&&e.removeAttribute(t),e._value=n;return}let s=!1;if(n===""||n==null){const l=typeof e[t];l==="boolean"?n=Or(n):n==null&&l==="string"?(n="",s=!0):l==="number"&&(n=0,s=!0)}try{e[t]=n}catch{}s&&e.removeAttribute(i||t)}function hn(e,t,n,o){e.addEventListener(t,n,o)}function ld(e,t,n,o){e.removeEventListener(t,n,o)}const xl=Symbol("_vei");function ad(e,t,n,o,i=null){const r=e[xl]||(e[xl]={}),s=r[t];if(o&&s)s.value=o;else{const[l,a]=cd(t);if(o){const u=r[t]=fd(o,i);hn(e,l,u,a)}else s&&(ld(e,l,s,a),r[t]=void 0)}}const _l=/(?:Once|Passive|Capture)$/;function cd(e){let t;if(_l.test(e)){t={};let o;for(;o=e.match(_l);)e=e.slice(0,e.length-o[0].length),t[o[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):Qe(e.slice(2)),t]}let Fi=0;const ud=Promise.resolve(),dd=()=>Fi||(ud.then(()=>Fi=0),Fi=Date.now());function fd(e,t){const n=o=>{if(!o._vts)o._vts=Date.now();else if(o._vts<=n.attached)return;wt(pd(o,n.value),t,5,[o])};return n.value=e,n.attached=dd(),n}function pd(e,t){if(re(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(o=>i=>!i._stopped&&o&&o(i))}else return t}const Sl=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,hd=(e,t,n,o,i,r)=>{const s=i==="svg";t==="class"?td(e,o,s):t==="style"?rd(e,n,o):so(t)?si(t)||ad(e,t,n,o,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):gd(e,t,o,s))?(wl(e,t,o),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&yl(e,t,o,s,r,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!$e(o))?wl(e,He(t),o,r,t):(t==="true-value"?e._trueValue=o:t==="false-value"&&(e._falseValue=o),yl(e,t,o,s))};function gd(e,t,n,o){if(o)return!!(t==="innerHTML"||t==="textContent"||t in e&&Sl(t)&&pe(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 i=e.tagName;if(i==="IMG"||i==="VIDEO"||i==="CANVAS"||i==="SOURCE")return!1}return Sl(t)&&$e(n)?!1:t in e}const kl={};function md(e,t,n){let o=ge(e,t);ao(o)&&(o=Oe({},o,t));class i extends Wi{constructor(s){super(o,s,n)}}return i.def=o,i}const vd=typeof HTMLElement<"u"?HTMLElement:class{};class Wi extends vd{constructor(t,n={},o=Ol){super(),this._def=t,this._props=n,this._createApp=o,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._patching=!1,this._dirty=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&o!==Ol?this._root=this.shadowRoot:t.shadowRoot!==!1?(this.attachShadow(Oe({},t.shadowRootOptions,{mode:"open"})),this._root=this.shadowRoot):this._root=this}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let t=this;for(;t=t&&(t.parentNode||t.host);)if(t instanceof Wi){this._parent=t;break}this._instance||(this._resolved?this._mount(this._def):t&&t._pendingResolve?this._pendingResolve=t._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(t=this._parent){t&&(this._instance.parent=t._instance,this._inheritParentContext(t))}_inheritParentContext(t=this._parent){t&&this._app&&Object.setPrototypeOf(this._app._context.provides,t._instance.provides)}disconnectedCallback(){this._connected=!1,pt(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&(this._teleportTargets.clear(),this._teleportTargets=void 0))})}_processMutations(t){for(const n of t)this._setAttr(n.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let o=0;o<this.attributes.length;o++)this._setAttr(this.attributes[o].name);this._ob=new MutationObserver(this._processMutations.bind(this)),this._ob.observe(this,{attributes:!0});const t=(o,i=!1)=>{this._resolved=!0,this._pendingResolve=void 0;const{props:r,styles:s}=o;let l;if(r&&!re(r))for(const a in r){const u=r[a];(u===Number||u&&u.type===Number)&&(a in this._props&&(this._props[a]=di(this._props[a])),(l||(l=Object.create(null)))[He(a)]=!0)}this._numberProps=l,this._resolveProps(o),this.shadowRoot&&this._applyStyles(s),this._mount(o)},n=this._def.__asyncLoader;n?this._pendingResolve=n().then(o=>{o.configureApp=this._def.configureApp,t(this._def=o,!0)}):t(this._def)}_mount(t){this._app=this._createApp(t),this._inheritParentContext(),t.configureApp&&t.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);const n=this._instance&&this._instance.exposed;if(n)for(const o in n)ke(this,o)||Object.defineProperty(this,o,{get:()=>X(n[o])})}_resolveProps(t){const{props:n}=t,o=re(n)?n:Object.keys(n||{});for(const i of Object.keys(this))i[0]!=="_"&&o.includes(i)&&this._setProp(i,this[i]);for(const i of o.map(He))Object.defineProperty(this,i,{get(){return this._getProp(i)},set(r){this._setProp(i,r,!0,!this._patching)}})}_setAttr(t){if(t.startsWith("data-v-"))return;const n=this.hasAttribute(t);let o=n?this.getAttribute(t):kl;const i=He(t);n&&this._numberProps&&this._numberProps[i]&&(o=di(o)),this._setProp(i,o,!1,!0)}_getProp(t){return this._props[t]}_setProp(t,n,o=!0,i=!1){if(n!==this._props[t]&&(this._dirty=!0,n===kl?delete this._props[t]:(this._props[t]=n,t==="key"&&this._app&&(this._app._ceVNode.key=n)),i&&this._instance&&this._update(),o)){const r=this._ob;r&&(this._processMutations(r.takeRecords()),r.disconnect()),n===!0?this.setAttribute(Qe(t),""):typeof n=="string"||typeof n=="number"?this.setAttribute(Qe(t),n+""):n||this.removeAttribute(Qe(t)),r&&r.observe(this,{attributes:!0})}}_update(){const t=this._createVNode();this._app&&(t.appContext=this._app._context),Td(t,this._root)}_createVNode(){const t={};this.shadowRoot||(t.onVnodeMounted=t.onVnodeUpdated=this._renderSlots.bind(this));const n=V(this._def,Oe(t,this._props));return this._instance||(n.ce=o=>{this._instance=o,o.ce=this,o.isCE=!0;const i=(r,s)=>{this.dispatchEvent(new CustomEvent(r,ao(s[0])?Oe({detail:s},s[0]):{detail:s}))};o.emit=(r,...s)=>{i(r,s),Qe(r)!==r&&i(Qe(r),s)},this._setParent()}),n}_applyStyles(t,n){if(!t)return;if(n){if(n===this._def||this._styleChildren.has(n))return;this._styleChildren.add(n)}const o=this._nonce;for(let i=t.length-1;i>=0;i--){const r=document.createElement("style");o&&r.setAttribute("nonce",o),r.textContent=t[i],this.shadowRoot.prepend(r)}}_parseSlots(){const t=this._slots={};let n;for(;n=this.firstChild;){const o=n.nodeType===1&&n.getAttribute("slot")||"default";(t[o]||(t[o]=[])).push(n),this.removeChild(n)}}_renderSlots(){const t=this._getSlots(),n=this._instance.type.__scopeId;for(let o=0;o<t.length;o++){const i=t[o],r=i.getAttribute("name")||"default",s=this._slots[r],l=i.parentNode;if(s)for(const a of s){if(n&&a.nodeType===1){const u=n+"-s",c=document.createTreeWalker(a,1);a.setAttribute(u,"");let d;for(;d=c.nextNode();)d.setAttribute(u,"")}l.insertBefore(a,i)}else for(;i.firstChild;)l.insertBefore(i.firstChild,i);l.removeChild(i)}}_getSlots(){const t=[this];this._teleportTargets&&t.push(...this._teleportTargets);const n=new Set;for(const o of t){const i=o.querySelectorAll("slot");for(let r=0;r<i.length;r++)n.add(i[r])}return Array.from(n)}_injectChildStyle(t){this._applyStyles(t.styles,t)}_beginPatch(){this._patching=!0,this._dirty=!1}_endPatch(){this._patching=!1,this._dirty&&this._instance&&this._update()}_removeChildStyle(t){}}const Uo=e=>{const t=e.props["onUpdate:modelValue"]||!1;return re(t)?n=>fo(t,n):t};function bd(e){e.target.composing=!0}function Cl(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Cn=Symbol("_assign");function Tl(e,t,n){return t&&(e=e.trim()),n&&(e=ui(e)),e}const yd={created(e,{modifiers:{lazy:t,trim:n,number:o}},i){e[Cn]=Uo(i);const r=o||i.props&&i.props.type==="number";hn(e,t?"change":"input",s=>{s.target.composing||e[Cn](Tl(e.value,n,r))}),(n||r)&&hn(e,"change",()=>{e.value=Tl(e.value,n,r)}),t||(hn(e,"compositionstart",bd),hn(e,"compositionend",Cl),hn(e,"change",Cl))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:o,trim:i,number:r}},s){if(e[Cn]=Uo(s),e.composing)return;const l=(r||e.type==="number")&&!/^0\d/.test(e.value)?ui(e.value):e.value,a=t??"";l!==a&&(document.activeElement===e&&e.type!=="range"&&(o&&t===n||i&&e.value.trim()===a)||(e.value=a))}},wd={deep:!0,created(e,t,n){e[Cn]=Uo(n),hn(e,"change",()=>{const o=e._modelValue,i=xd(e),r=e.checked,s=e[Cn];if(re(o)){const l=$r(o,i),a=l!==-1;if(r&&!a)s(o.concat(i));else if(!r&&a){const u=[...o];u.splice(l,1),s(u)}}else if(lo(o)){const l=new Set(o);r?l.add(i):l.delete(i),s(l)}else s(Pl(e,r))})},mounted:Ml,beforeUpdate(e,t,n){e[Cn]=Uo(n),Ml(e,t,n)}};function Ml(e,{value:t,oldValue:n},o){e._modelValue=t;let i;if(re(t))i=$r(t,o.props.value)>-1;else if(lo(t))i=t.has(o.props.value);else{if(t===n)return;i=ho(t,Pl(e,!0))}e.checked!==i&&(e.checked=i)}function xd(e){return"_value"in e?e._value:e.value}function Pl(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const _d=["ctrl","shift","alt","meta"],Sd={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)=>_d.some(n=>e[`${n}Key`]&&!t.includes(n))},Be=(e,t)=>{const n=e._withMods||(e._withMods={}),o=t.join(".");return n[o]||(n[o]=(i,...r)=>{for(let s=0;s<t.length;s++){const l=Sd[t[s]];if(l&&l(i,t))return}return e(i,...r)})},kd={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},qo=(e,t)=>{const n=e._withKeys||(e._withKeys={}),o=t.join(".");return n[o]||(n[o]=i=>{if(!("key"in i))return;const r=Qe(i.key);if(t.some(s=>s===r||kd[s]===r))return e(i)})},Cd=Oe({patchProp:hd},Yu);let El;function Il(){return El||(El=vu(Cd))}const Td=(...e)=>{Il().render(...e)},Ol=(...e)=>{const t=Il().createApp(...e),{mount:n}=t;return t.mount=o=>{const i=Pd(o);if(!i)return;const r=t._component;!pe(r)&&!r.render&&!r.template&&(r.template=i.innerHTML),i.nodeType===1&&(i.textContent="");const s=n(i,!1,Md(i));return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),s},t};function Md(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Pd(e){return $e(e)?document.querySelector(e):e}function gn(e,t){if(typeof e.checkVisibility=="function")return e.checkVisibility({opacityProperty:!0,visibilityProperty:!1,contentVisibilityAuto:!1});const n=window.getComputedStyle(e);if(n.display==="none"||n.opacity&&parseFloat(n.opacity)<.1)return!1;if(!t)return!0;const o=e.parentElement;return!o||o===t?!0:gn(o,t)}async function en(e,t,n){const o=await n(()=>{e=0});if(o!==void 0)return o;if(!(e<=0))return await new Promise(i=>{setTimeout(async()=>{const r=await en(e-1,t,n);i(r)},t)})}function Qn(e,t){return e>=280&&t>=50||e>=160&&t>=280}var Kt;(function(e){e[e.manga=1]="manga",e[e.novel=2]="novel",e[e.anime=3]="anime"})(Kt||(Kt={}));async function Ed(e,t){const n=["NAV","ASIDE","FOOTER","HEADER","BR","HR","BUTTON","A"],o="img:not(nav img, header img, footer img, aside img), canvas",i=t==null?void 0:t.timeoutMs,r=t==null?void 0:t.include,s=t==null?void 0:t.paraSel,l=!r||r.includes(Kt.manga),a=!r||r.includes(Kt.novel);let u=0;return await en(i/50,50,()=>{const h=c();if(h){if(l&&f(h,t==null?void 0:t.validateImgSize))return Kt.manga;if(a&&u++%3===0&&d(h))return Kt.novel}});function c(){for(const h of e.split(",")){const w=document.querySelector(h);if(w)return w}}function d(h){const w=[`p:not(${n.map(A=>`${A} p`).join(",")})`,s].filter(Boolean).join(",");if(!h.querySelector(w)&&(!s||!h.matches(s)))return!1;let y=0,$=0,k=0;return B(h);function B(A){const b=A.tagName;if(n.includes(b)||!gn(A)||window.getComputedStyle(A).position==="fixed")return!1;if(b==="P"||s&&A.matches(s))return y+=A.textContent.split(" ").filter(Boolean).length,$++,k=0,!l&&y>50||$>10&&y>120||$>5&&y>250||y>400;$>0&&++k>4&&($=0,y=0);const E=Array.from(A.children);for(let L=0;L<E.length;L++)if(B(E[L]))return!0;return!1}}function f(h,w){const y=Array.from(h.querySelectorAll(o));if(w===!1)return y.length>0;const $=Math.min(window.innerWidth*.9,500);let k=0;for(let B=0;B<y.length;B++){const A=y[B];if(!gn(A,h))continue;const{width:b,height:g}=A.getBoundingClientRect();if(Qn(b,g)&&(b>=$||(k+=g,k>=$)))return!0}return!1}}function Ui(e,t){return pi()?(nc(e,t),!0):!1}const qi=new WeakMap,Id=(...e)=>{var t;const n=e[0],o=(t=dn())===null||t===void 0?void 0:t.proxy,i=o??pi();if(i==null&&!Is())throw new Error("injectLocal must be called in setup");return i&&qi.has(i)&&n in qi.get(i)?qi.get(i)[n]:Ft(...e)},$l=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Od=e=>e!=null,$d=Object.prototype.toString,zd=e=>$d.call(e)==="[object Object]",Tn=()=>{};function Dd(...e){if(e.length!==1)return Ec(...e);const t=e[0];return typeof t=="function"?Ln(ts(()=>({get:t,set:Tn}))):te(t)}function zl(e,t){function n(...o){return new Promise((i,r)=>{Promise.resolve(e(()=>t.apply(this,o),{fn:t,thisArg:this,args:o})).then(i).catch(r)})}return n}const Dl=e=>e();function Ad(e,t={}){let n,o,i=Tn;const r=a=>{clearTimeout(a),i(),i=Tn};let s;return a=>{const u=ft(e),c=ft(t.maxWait);return n&&r(n),u<=0||c!==void 0&&c<=0?(o&&(r(o),o=void 0),Promise.resolve(a())):new Promise((d,f)=>{i=t.rejectOnCancel?f:d,s=a,c&&!o&&(o=setTimeout(()=>{n&&r(n),o=void 0,d(s())},c)),n=setTimeout(()=>{o&&r(o),o=void 0,d(a())},u)})}}function Ld(e=Dl,t={}){const{initialState:n="active"}=t,o=Dd(n==="active");function i(){o.value=!1}function r(){o.value=!0}const s=(...l)=>{o.value&&e(...l)};return{isActive:Ln(o),pause:i,resume:r,eventFilter:s}}function Al(e){return e.endsWith("rem")?Number.parseFloat(e)*16:Number.parseFloat(e)}function eo(e){return Array.isArray(e)?e:[e]}function jd(e){return dn()}function gt(e,t=200,n={}){return zl(Ad(t,n),e)}function Bd(e,t,n={}){const{eventFilter:o=Dl,...i}=n;return de(e,zl(o,t),i)}function Nd(e,t,n={}){const{eventFilter:o,initialState:i="active",...r}=n,{eventFilter:s,pause:l,resume:a,isActive:u}=Ld(o,{initialState:i});return{stop:Bd(e,t,{...r,eventFilter:s}),pause:l,resume:a,isActive:u}}const Vd=Nd;function Ki(e,t=!0,n){jd()?je(e,n):t?e():pt(e)}function Rd(e,t,n){return de(e,t,{...n,immediate:!0})}const xt=$l?window:void 0,Hd=$l?window.document:void 0;function Ot(e){var t;const n=ft(e);return(t=n==null?void 0:n.$el)!==null&&t!==void 0?t:n}function _t(...e){const t=[],n=()=>{t.forEach(l=>l()),t.length=0},o=(l,a,u,c)=>(l.addEventListener(a,u,c),()=>l.removeEventListener(a,u,c)),i=Q(()=>{const l=eo(ft(e[0])).filter(a=>a!=null);return l.every(a=>typeof a!="string")?l:void 0}),r=Rd(()=>{var l,a;return[(l=(a=i.value)===null||a===void 0?void 0:a.map(u=>Ot(u)))!==null&&l!==void 0?l:[xt].filter(u=>u!=null),eo(ft(i.value?e[1]:e[0])),eo(X(i.value?e[2]:e[1])),ft(i.value?e[3]:e[2])]},([l,a,u,c])=>{if(n(),!(l!=null&&l.length)||!(a!=null&&a.length)||!(u!=null&&u.length))return;const d=zd(c)?{...c}:c;t.push(...l.flatMap(f=>a.flatMap(h=>u.map(w=>o(f,h,w,d)))))},{flush:"post"}),s=()=>{r(),n()};return Ui(n),s}function Fd(){const e=dt(!1),t=dn();return t&&je(()=>{e.value=!0},t),e}function Zi(e){const t=Fd();return Q(()=>(t.value,!!e()))}const Wd=Symbol("vueuse-ssr-width");function Ud(){const e=Is()?Id(Wd,null):null;return typeof e=="number"?e:void 0}function qd(e,t={}){const{window:n=xt,ssrWidth:o=Ud()}=t,i=Zi(()=>n&&"matchMedia"in n&&typeof n.matchMedia=="function"),r=dt(typeof o=="number"),s=dt(),l=dt(!1),a=u=>{l.value=u.matches};return Fs(()=>{if(r.value){r.value=!i.value,l.value=ft(e).split(",").some(u=>{const c=u.includes("not all"),d=u.match(/\(\s*min-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/),f=u.match(/\(\s*max-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/);let h=!!(d||f);return d&&h&&(h=o>=Al(d[1])),f&&h&&(h=o<=Al(f[1])),c?!h:h});return}i.value&&(s.value=n.matchMedia(ft(e)),l.value=s.value.matches)}),_t(s,"change",a,{passive:!0}),Q(()=>l.value)}const Ko=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Zo="__vueuse_ssr_handlers__",Kd=Zd();function Zd(){return Zo in Ko||(Ko[Zo]=Ko[Zo]||{}),Ko[Zo]}function Yd(e,t){return Kd[e]||t}function Xd(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const Gd={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Ll="vueuse-storage";function Jd(e,t,n,o={}){var i;const{flush:r="pre",deep:s=!0,listenToStorageChanges:l=!0,writeDefaults:a=!0,mergeDefaults:u=!1,shallow:c,window:d=xt,eventFilter:f,onError:h=C=>{console.error(C)},initOnMounted:w}=o,y=(c?dt:te)(typeof t=="function"?t():t),$=Q(()=>ft(e));if(!n)try{n=Yd("getDefaultStorage",()=>xt==null?void 0:xt.localStorage)()}catch(C){h(C)}if(!n)return y;const k=ft(t),B=Xd(k),A=(i=o.serializer)!==null&&i!==void 0?i:Gd[B],{pause:b,resume:g}=Vd(y,C=>O(C),{flush:r,deep:s,eventFilter:f});de($,()=>M(),{flush:r});let E=!1;const L=C=>{w&&!E||M(C)},Z=C=>{w&&!E||G(C)};d&&l&&(n instanceof Storage?_t(d,"storage",L,{passive:!0}):_t(d,Ll,Z)),w?Ki(()=>{E=!0,M()}):M();function _(C,ee){if(d){const W={key:$.value,oldValue:C,newValue:ee,storageArea:n};d.dispatchEvent(n instanceof Storage?new StorageEvent("storage",W):new CustomEvent(Ll,{detail:W}))}}function O(C){try{const ee=n.getItem($.value);if(C==null)_(ee,null),n.removeItem($.value);else{const W=A.write(C);ee!==W&&(n.setItem($.value,W),_(ee,W))}}catch(ee){h(ee)}}function j(C){const ee=C?C.newValue:n.getItem($.value);if(ee==null)return a&&k!=null&&n.setItem($.value,A.write(k)),k;if(!C&&u){const W=A.read(ee);return typeof u=="function"?u(W,k):B==="object"&&!Array.isArray(W)?{...k,...W}:W}else return typeof ee!="string"?ee:A.read(ee)}function M(C){if(!(C&&C.storageArea!==n)){if(C&&C.key==null){y.value=k;return}if(!(C&&C.key!==$.value)){b();try{const ee=A.write(y.value);(C===void 0||(C==null?void 0:C.newValue)!==ee)&&(y.value=j(C))}catch(ee){h(ee)}finally{C?pt(g):g()}}}}function G(C){M(C.detail)}return y}function Yi(e={}){const{document:t=Hd}=e;if(!t)return dt("visible");const n=dt(t.visibilityState);return _t(t,"visibilitychange",()=>{n.value=t.visibilityState},{passive:!0}),n}function Qd(e,t,n={}){const{window:o=xt,...i}=n;let r;const s=Zi(()=>o&&"ResizeObserver"in o),l=()=>{r&&(r.disconnect(),r=void 0)},a=de(Q(()=>{const c=ft(e);return Array.isArray(c)?c.map(d=>Ot(d)):[Ot(c)]}),c=>{if(l(),s.value&&o){r=new ResizeObserver(t);for(const d of c)d&&r.observe(d,i)}},{immediate:!0,flush:"post"}),u=()=>{l(),a()};return Ui(u),{isSupported:s,stop:u}}function jl(e,t={width:0,height:0},n={}){const{window:o=xt,box:i="content-box"}=n,r=Q(()=>{var d;return(d=Ot(e))===null||d===void 0||(d=d.namespaceURI)===null||d===void 0?void 0:d.includes("svg")}),s=dt(t.width),l=dt(t.height),{stop:a}=Qd(e,([d])=>{const f=i==="border-box"?d.borderBoxSize:i==="content-box"?d.contentBoxSize:d.devicePixelContentBoxSize;if(o&&r.value){const h=Ot(e);if(h){const w=h.getBoundingClientRect();s.value=w.width,l.value=w.height}}else if(f){const h=eo(f);s.value=h.reduce((w,{inlineSize:y})=>w+y,0),l.value=h.reduce((w,{blockSize:y})=>w+y,0)}else s.value=d.contentRect.width,l.value=d.contentRect.height},n);Ki(()=>{const d=Ot(e);d&&(s.value="offsetWidth"in d?d.offsetWidth:t.width,l.value="offsetHeight"in d?d.offsetHeight:t.height)});const u=de(()=>Ot(e),d=>{s.value=d?t.width:0,l.value=d?t.height:0});function c(){a(),u()}return{width:s,height:l,stop:c}}function ef(e,t,n={}){const{root:o,rootMargin:i="0px",threshold:r=0,window:s=xt,immediate:l=!0}=n,a=Zi(()=>s&&"IntersectionObserver"in s),u=Q(()=>eo(ft(e)).map(Ot).filter(Od));let c=Tn;const d=dt(l),f=a.value?de(()=>[u.value,Ot(o),d.value],([w,y])=>{if(c(),!d.value||!w.length)return;const $=new IntersectionObserver(t,{root:Ot(y),rootMargin:i,threshold:r});w.forEach(k=>k&&$.observe(k)),c=()=>{$.disconnect(),c=Tn}},{immediate:l,flush:"post"}):Tn,h=()=>{c(),f(),d.value=!1};return Ui(h),{isSupported:a,isActive:d,pause(){c(),d.value=!1},resume(){d.value=!0},stop:h}}function tf(e,t,n={}){const{window:o=xt}=n;return Jd(e,t,o==null?void 0:o.localStorage,n)}function mn(e={}){const{window:t=xt,initialWidth:n=Number.POSITIVE_INFINITY,initialHeight:o=Number.POSITIVE_INFINITY,listenOrientation:i=!0,includeScrollbar:r=!0,type:s="inner"}=e,l=dt(n),a=dt(o),u=()=>{if(t)if(s==="outer")l.value=t.outerWidth,a.value=t.outerHeight;else if(s==="visual"&&t.visualViewport){const{width:d,height:f,scale:h}=t.visualViewport;l.value=Math.round(d*h),a.value=Math.round(f*h)}else r?(l.value=t.innerWidth,a.value=t.innerHeight):(l.value=t.document.documentElement.clientWidth,a.value=t.document.documentElement.clientHeight)};u(),Ki(u);const c={passive:!0};return _t("resize",u,c),t&&s==="visual"&&t.visualViewport&&_t(t.visualViewport,"resize",u,c),i&&de(qd("(orientation: portrait)"),()=>u()),{width:l,height:a}}class to{static register(t){this.handlers.push(t)}static unregister(t){const n=this.handlers.indexOf(t);n!==-1&&this.handlers.splice(n,1)}static trigger(){for(const t of this.handlers)if(t())return!0;return!1}static clear(){this.handlers=[]}}Pe(to,"handlers",[]);function Xi(e){je(()=>to.register(e)),Pt(()=>to.unregister(e))}const Bl=ge({__name:"HelpScreen",props:{touchDevice:{type:Boolean}},emits:["hide"],setup(e,{emit:t}){const n=e,o=t,i=te(null),r=te([]);Xi(()=>(o("hide"),!0)),je(async()=>{const u=jl(i),c=gt(()=>{s({width:u.width.value,height:u.height.value})},50);c(),de(u.width,c),de(u.height,c)});function s(u){var f;const c=(f=i.value)==null?void 0:f.parentElement;if(!c)return;const d=Array.from(c.querySelectorAll("#controls [title], #top-controls [title], #bottom-controls [title]"));d.length&&(r.value=l(d,u))}function l(u,c){const d=[],f=[];let h=0,w=0;const y=50,$=25;u.forEach(g=>{var O;const E=(O=g.getAttribute("title"))==null?void 0:O.trim(),L=g.getBoundingClientRect();if(!E||!L.height||!L.width)return;const Z=Math.ceil((L.top-10)/y),_=Math.ceil((L.left-10)/y);f.push({isTour:!1,title:E,rect:L,fromX:_,toX:Math.max(_+1,Math.ceil((L.right+10)/y)),fromY:Z,toY:Math.max(Z+1,Math.ceil((L.bottom+10)/y))})}),f.forEach(g=>{for(let E=g.fromY;E<g.toY;E++){d[E]??(d[E]=[]);for(let L=g.fromX;L<g.toX;L++)d[E][L]=g;g.toY>h+1&&(h=g.toY-1),g.toX>w+1&&(w=g.toX-1)}});let k=w/2;f.forEach(g=>{g.isAlignRight=g.fromX>k});const B=(g,E)=>{d[E]??(d[E]=[]);const L=E>=g.toY;if(g.isTour)for(let Z=g.fromX;Z<g.toX;Z++)delete d[g.fromY][Z],g.fromY=E,g.toY=E+(L?1:-1),d[E][Z]=g;else{const Z=g.isAlignRight?g.fromX-3:g.fromX,_=Z+3;g.helpItem={fromX:Z,toX:_,fromY:E,toY:E+1,isTour:!0,isAlignRight:g.isAlignRight};for(let O=Z;O<_;O++)d[E][O]=g.helpItem}},A=(g,E)=>{if(E>h||E<0)return!1;const L=E>=g.toY,Z=d[E];if(!Z)return B(g,E),!0;const _=Z[g.fromX];if(_&&!_.isTour)return!1;if(_&&_.isTour)return A(_,L?E+1:E-1)?(B(g,E),!0):!1;if(!_){const O=g.isAlignRight?-1:1;return Z[g.fromX+O]||Z[g.fromX+O*2]?A(g,L?E+1:E-1):(B(g,E),!0)}return!1};f.forEach(g=>{if(!A(g,g.toY)){if(g.isAlignRight){const E=d[g.fromY]??[];if(!E.slice(g.fromX-3,g.fromX).filter(Boolean).length){const Z=g.fromX-3,_=g.fromX;g.helpItem={isTour:!0,isAlignRight:!0,fromX:Z,toX:_,fromY:g.fromY,toY:g.toY};for(let O=g.fromX-3;O<g.fromX;O++)E[O]=g.helpItem;return}}A(g,g.fromY-1)}});const b=[];return f.forEach(g=>{const{title:E,helpItem:L,rect:Z,isAlignRight:_,fromX:O,fromY:j,toY:M}=g;if(!E||!L||!Z)return;const G=L.fromY>=M,C=L.toY<=j;b.push({title:a(E),style:{top:G?`${Z.bottom+(L.fromY-M)*y+$}px`:C?void 0:`${Z.top+8}px`,bottom:C?`${c.height-Z.top+(L.toY-j)*y+$}px`:void 0,left:_?void 0:`${Z.left}px`,right:_?G?`${c.width-Z.right}px`:`${c.width-Z.right+Z.width+$}px`:void 0},arrowStyle:{width:C||G?"2px":`${Math.abs(L.toX-O)*y+$-5}px`,height:C||G?`${(G?L.fromY-M:j-L.toY)*y+$}px`:"2px",top:G?`${Z.bottom}px`:C?void 0:`${Z.top+20}px`,bottom:C?`${c.height-Z.top}px`:void 0,left:_?void 0:`${Z.left+Z.width/2}px`,right:_?G?`${c.width-Z.right+Z.width/2}px`:`${c.width-Z.right+Z.width}px`:void 0}})}),b}function a(u){return n.touchDevice?u.split("(")[0].trim():u}return(u,c)=>(v(),z(ye,null,[c[1]||(c[1]=Y("div",{class:"fixed inset-0 bg-black bg-opacity-90"},null,-1)),Y("div",{ref_key:"root",ref:i,class:"fixed inset-0 z-20 overscroll-contain select-none",onClick:c[0]||(c[0]=Be(d=>o("hide"),["stop"]))},[(v(!0),z(ye,null,Xt(r.value,d=>(v(),z(ye,{key:d.title},[Y("div",{class:"absolute",style:Ce(d.style)},Fe(d.title),5),Y("div",{class:"absolute bg-stone-300 rounded-lg",style:Ce(d.arrowStyle)},null,4)],64))),128))],512)],64))}}),nf=Object.freeze(Object.defineProperty({__proto__:null,default:Bl},Symbol.toStringTag,{value:"Module"}));function Mn(e,t){let n=null;return(...o)=>{n===null&&(n=setTimeout(()=>{n=null,e(...o)},t))}}const of=ge({__name:"ReaderTour",emits:["hide"],setup(e,{emit:t}){const n=t,o=te(null),i=te(0),r=te([]),s=Q(()=>r.value[i.value]),l=Mn(a,500);je(()=>{const d=jl(o),f=gt(()=>u({width:d.width.value,height:d.height.value}),50);f(),de(d.width,f),de(d.height,f)});function a(){i.value>=r.value.length-1?n("hide"):i.value++}function u(d){const f=c();r.value=f.map(({rect:h,text:w})=>{const y=h.top<d.height-h.bottom,$=h.left<d.width-h.right;return{text:w,style:{left:`${h.left}px`,top:`${h.top}px`,width:`${h.width}px`,height:`${h.height}px`},textStyle:{left:$?`${h.left-12}px`:void 0,right:$?void 0:`${d.width-h.left}px`,top:y?`${h.bottom+12}px`:`${h.top+20}px`,textAlign:y?void 0:"right",transform:y?void 0:"translateY(-50%)"}}}),i.value>=r.value.length&&(i.value=r.value.length-1)}function c(){var h;const d=(h=o.value)==null?void 0:h.parentElement;if(!d)return[];const f=[];return d.querySelectorAll("[data-tour]").forEach(w=>{var k;const y=(k=w.getAttribute("data-tour"))==null?void 0:k.trim();if(!(y!=null&&y.length))return;const $=w.getBoundingClientRect();f.push({rect:$,text:y})}),f}return(d,f)=>{var h,w;return v(),z(ye,null,[Y("div",{class:ue(["fixed inset-0 bg-black bg-opacity-50 duration-500",{"opacity-0":!s.value,"opacity-100":!!s.value}])},null,2),Y("div",{ref_key:"root",ref:o,class:"tour",onClick:f[0]||(f[0]=Be((...y)=>X(l)&&X(l)(...y),["stop"]))},[s.value?(v(),z("div",{key:i.value,class:"tour__target",style:Ce(s.value.style)},null,4)):le("",!0),(v(),z("div",{key:i.value,class:"tour__text",style:Ce((h=s.value)==null?void 0:h.textStyle)},Fe(((w=s.value)==null?void 0:w.text)??""),5))],512)],64)}}}),rf=".tour{height:100%;left:0;overflow:hidden;position:fixed;top:0;width:100%;z-index:20}.tour__target{border-radius:9999px;border-width:2px;--tw-border-opacity:1;animation:tour-target-anim .5s forwards;border-color:rgb(120 113 108/var(--tw-border-opacity,1));box-shadow:0 0 0 99999px #000000e6}.tour__target,.tour__text{position:absolute}.tour__text{animation:tour-text-anim 1s forwards,tour-text-bounce .75s ease-in-out infinite alternate;max-width:320px;padding-left:12px;padding-right:12px;transition-duration:1s}@keyframes tour-target-anim{0%{transform:scale(3);--tw-border-opacity:0;opacity:0}to{transform:scale(1);--tw-border-opacity:1;opacity:.9}}@keyframes tour-text-anim{0%{opacity:0}to{opacity:1}}@keyframes tour-text-bounce{0%{margin-top:0}to{margin-top:.625}}",be=(e,t)=>{const n=e.__vccOpts||e;for(const[o,i]of t)n[o]=i;return n},Nl=be(of,[["styles",[rf]]]),sf=Object.freeze(Object.defineProperty({__proto__:null,default:Nl},Symbol.toStringTag,{value:"Module"}));function lf({touchDevice:e}){const t=te(!1);let n=0;return Fn("busy:touchDevice",e),Fn("setBusyState",o=>{n+=o?1:-1;const i=n>0;t.value!=i&&(t.value=i)}),Q(()=>t.value)}function Yo(){const e=Ft("busy:touchDevice"),t=Ft("setBusyState");let n=!1;return Pt(()=>{n&&(t==null||t(!1))}),(o,{desktopOnly:i=!1}={})=>{i&&e||(n=o,t==null||t(o))}}function af(e){Fn("hapticFeedback",e)}function Xo(){return Ft("hapticFeedback")}class cf{constructor(){Pe(this,"listeners");this.listeners=[],this.onKeyDown=this.onKeyDown.bind(this),this.onKeyUp=this.onKeyUp.bind(this),this.init()}init(){window.addEventListener("keydown",this.onKeyDown,{capture:!0}),window.addEventListener("keyup",this.onKeyUp,{capture:!0}),window.addEventListener("keypress",this.onKeyPress,{capture:!0})}dispose(){window.removeEventListener("keydown",this.onKeyDown,{capture:!0}),window.removeEventListener("keyup",this.onKeyUp,{capture:!0}),window.removeEventListener("keypress",this.onKeyPress,{capture:!0})}onKeyPress(t){t.stopImmediatePropagation(),t.stopPropagation()}onKeyDown(t){var n,o;t.stopImmediatePropagation(),t.stopPropagation();for(let i=0;i<this.listeners.length&&((o=(n=this.listeners[i]).onKeyDown)==null?void 0:o.call(n,t))!==!0;i++);}onKeyUp(t){var n,o;t.stopImmediatePropagation(),t.stopPropagation();for(let i=0;i<this.listeners.length&&((o=(n=this.listeners[i]).onKeyUp)==null?void 0:o.call(n,t))!==!0;i++);}addListener(t){this.listeners.push(t)}removeListener(t){const n=this.listeners.indexOf(t);n!==-1&&this.listeners.splice(n,1)}}function uf(){const e=new cf;return Pt(()=>e.dispose()),Fn("keyController",e),e}function $t(e){const t=Ft("keyController");je(()=>t.addListener(e)),Pt(()=>t.removeListener(e))}function df(e,t){const n=sessionStorage.getItem("tk:page:path");n!==location.pathname&&(sessionStorage.setItem("tk:page:path",location.pathname),n&&sessionStorage.removeItem("tk:page"));const o=te(t&&e>0?Math.max(0,e):+(sessionStorage.getItem("tk:page")??"0")||e);return Q({get:()=>o.value,set:i=>{o.value=i,sessionStorage.setItem("tk:page",i+"")}})}function ff(){sessionStorage.removeItem("tk:page"),sessionStorage.removeItem("tk:page:path")}const pf=(e,t)=>{const n=+(e.getAttribute("data-ripple")??0);if(!n)return;const o=document.createElement("span");let i=1,r=.65;const s=setInterval(a,20);l();function l(){o.style.position="absolute",o.style.height="5px",o.style.width="5px",o.style.borderRadius="100%",o.style.backgroundColor="#f2f2f2",o.style.left=`${t.currentTarget.clientWidth/2}px`,o.style.top=`${t.currentTarget.clientHeight/2}px`,t.currentTarget.appendChild(o)}function a(){const u=+n||50;i<=u?(i++,r-=.65/u,o.style.transform=`scale(${i})`,o.style.opacity=`${r}`):(o.remove(),clearInterval(s))}},zt={mounted:(e,t)=>{e.style.position="relative",e.style.overflow="hidden",e.setAttribute("data-ripple",t.value),e.addEventListener("click",n=>pf(e,n))},updated:(e,t)=>{e.setAttribute("data-ripple",t.value)}},hf={class:"group-hover:bg-stone-100 group-hover:bg-opacity-20 transition-bg duration-200 rounđe-full p-2 w-full h-full inline-flex justify-center items-center gap-2 text-base"},Gi=ge({inheritAttrs:!1,__name:"BaseButton",props:{disabled:{type:Boolean},href:{type:String},transparent:{type:Boolean},title:{type:String},enableHapticFeedback:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=e,o=t,i=Yo(),r=Xo();let s=!1;function l(){s||(s=!0,i(!0,{desktopOnly:!0}))}function a(){s&&(s=!1,i(!1,{desktopOnly:!0}))}function u(c){n.disabled?c.preventDefault():(o("click",c),n.enableHapticFeedback&&r())}return(c,d)=>Re((v(),ie(xs(e.href?"a":"button"),kn({href:e.href,title:e.title},{class:["h-10 max-w-full max-h-full rounded-full flex-shrink-0 focus:outline-none outline-none",{"cursor-default opacity-60":e.disabled,"hover:text-stone-100 group duration-200":!e.disabled,"bg-black bg-opacity-50":!e.transparent,[`${c.$attrs.class??""}`]:!0}],onClick:Be(u,["stop"]),onMouseenter:l,onMouseleave:a}),{default:oe(()=>[Y("div",hf,[Se(c.$slots,"default")])]),_:3},16,["class"])),[[X(zt),e.disabled?0:15]])}}),gf=Object.freeze(Object.defineProperty({__proto__:null,default:Gi},Symbol.toStringTag,{value:"Module"})),mf={},vf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function bf(e,t){return v(),z("svg",vf,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M19 12.998h-6v6h-2v-6H5v-2h6v-6h2v6h6z"},null,-1)])])}const Vl=be(mf,[["render",bf]]),yf=Object.freeze(Object.defineProperty({__proto__:null,default:Vl},Symbol.toStringTag,{value:"Module"})),wf={class:"h-screen w-full flex justify-center items-center relative"},xf={key:0,class:"flex gap-6 p-6 duration-200"},_f={key:0,class:"inline-block rounded-full relative w-28 h-12 overflow-hidden"},Sf={key:0,class:"absolute bottom-0 left-0 right-0 flex justify-center pb-7 md:pb-6 lg:pb-4"},kf={class:"flex justify-center items-center gap-1 pl-1 pr-2 h-full"},Ji=be(ge({__name:"AutoNext",props:{hasNext:{type:Boolean},offlineMode:{type:Boolean},seconds:{type:Number},showAddButton:{type:Boolean}},emits:["next","hide","add-to-library","visibility-changed"],setup(e,{emit:t}){const n=e,o=t,i=te(null),r=te(!1),s=te(n.seconds),l=te(n.seconds<=0),a=te(n.seconds),u=Xo();je(()=>{let f;ef(i,h=>{const w=h.some(y=>y.isIntersecting);w!==r.value&&(r.value=w,o("visibility-changed",w),l.value=n.seconds<=0,s.value=n.seconds,a.value=n.seconds,f&&(clearInterval(f),f=void 0),!(!r.value||l.value)&&(f=setInterval(()=>{s.value-=1,s.value<=0&&(clearInterval(f),f=void 0,o("next"))},1e3)))},{rootMargin:"-108px 0px"}),Pt(()=>f&&clearInterval(f))});function c(){o("next"),u()}function d(){o("hide")}return(f,h)=>(v(),z("div",wf,[Y("div",{ref_key:"main",ref:i,class:"inline-flex text-base text-stone-300 select-none"},[V(Gn,{"enter-from-class":"opacity-0","leave-to-class":"opacity-0"},{default:oe(()=>[r.value?(v(),z("div",xf,[e.hasNext?(v(),z("div",_f,[r.value?(v(),z("div",{key:0,class:"absolute left-0 top-0 bottom-0 h-full bg-stone-600 bg-opacity-50",style:Ce(l.value?{}:{animation:`auto-next ${a.value}s linear forwards`})},null,4)):le("",!0),Re((v(),z("button",{class:"bg-transparent rounded-full h-full w-full border-solid border-stone-600 border-2 hover:bg-stone-300 hover:bg-opacity-10 totalDuration-200",onClick:Be(c,["stop"])},[Wt(Fe(l.value?"Next":`Next in ${s.value}`),1)])),[[X(zt)]])])):le("",!0),Re((v(),z("button",{class:"rounded-full px-6 h-12 bg-transparent border-solid border-stone-600 border-2 hover:bg-stone-300 hover:bg-opacity-10 totalDuration-200",onClick:Be(d,["stop"])},[Wt(Fe(e.offlineMode?"Close":"Hide"),1)])),[[X(zt)]])])):le("",!0)]),_:1})],512),e.showAddButton?(v(),z("div",Sf,[V(Gi,{class:"bg-primary w-min !h-9 !bg-opacity-100",onClick:h[0]||(h[0]=()=>o("add-to-library"))},{default:oe(()=>[Y("div",kf,[V(Vl,{class:"flex-shrink-0 w-auto"}),h[1]||(h[1]=Y("span",{class:"text-sm text-stone-50"},"Add to library",-1))])]),_:1})])):le("",!0)]))}}),[["styles",[".animate-auto-next{animation:auto-next 5s linear forwards}@keyframes auto-next{0%{width:0}to{width:100%}}"]]]),Cf=Object.freeze(Object.defineProperty({__proto__:null,default:Ji},Symbol.toStringTag,{value:"Module"})),Ge=ge({inheritAttrs:!1,__name:"ButtonIcon",props:{disabled:{type:Boolean},href:{type:String},title:{type:String},transparent:{type:Boolean},enableHapticFeedback:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;return(o,i)=>(v(),ie(Gi,{class:ue(["w-10",o.$attrs.class]),disabled:e.disabled,href:e.href,title:e.title,transparent:e.transparent,"enable-haptic-feedback":e.enableHapticFeedback,onClick:i[0]||(i[0]=r=>n("click",r))},{default:oe(()=>[Se(o.$slots,"default")]),_:3},8,["class","disabled","href","title","transparent","enable-haptic-feedback"]))}}),Tf=Object.freeze(Object.defineProperty({__proto__:null,default:Ge},Symbol.toStringTag,{value:"Module"})),Mf={},Pf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Ef(e,t){return v(),z("svg",Pf,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"m10.875 19.3l-6.6-6.6q-.15-.15-.213-.325T4 12q0-.2.063-.375t.212-.325l6.6-6.6q.275-.275.688-.287t.712.287q.3.275.313.688T12.3 6.1L7.4 11h11.175q.425 0 .713.288t.287.712q0 .425-.287.713t-.713.287H7.4l4.9 4.9q.275.275.288.7t-.288.7q-.275.3-.7.3t-.725-.3Z"},null,-1)])])}const Rl=be(Mf,[["render",Ef]]),If=Object.freeze(Object.defineProperty({__proto__:null,default:Rl},Symbol.toStringTag,{value:"Module"})),Qi=ge({__name:"ButtonBack",props:{offlineMode:{type:Boolean},raw:{type:null},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=e,o=t;function i(r){n.offlineMode&&(r.preventDefault(),o("click"))}return(r,s)=>{var l;return v(),ie(Ge,{href:e.offlineMode||!e.raw?"#":e.raw.title.url,title:`Back to ${((l=e.raw)==null?void 0:l.contentType)===X(Kt).novel?"novel":"manga"}`,transparent:e.transparent,"enable-haptic-feedback":"",onClick:i},{default:oe(()=>[V(Rl)]),_:1},8,["href","title","transparent"])}}}),Of=Object.freeze(Object.defineProperty({__proto__:null,default:Qi},Symbol.toStringTag,{value:"Module"})),$f={},zf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Df(e,t){return v(),z("svg",zf,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M17.825 8.575q-.2 0-.375-.062t-.325-.213L15.7 6.875q-.3-.3-.3-.712t.3-.688q.275-.3.7-.3t.7.275l.725.725l2.825-2.85q.3-.3.7-.3t.725.3q.275.3.275.725t-.275.7l-3.55 3.55q-.15.15-.325.213t-.375.062ZM6.4 20.4q-.5.2-.95-.087T5 19.475V5q0-.825.588-1.413T7 3h7q-.5.75-.75 1.438T13 6q0 1.8 1.137 3.175T17 10.9q.575.075 1 .075t1-.075v8.575q0 .55-.45.838t-.95.087L12 18l-5.6 2.4Z"},null,-1)])])}const Hl=be($f,[["render",Df]]),Af=Object.freeze(Object.defineProperty({__proto__:null,default:Hl},Symbol.toStringTag,{value:"Module"})),Lf={},jf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Bf(e,t){return v(),z("svg",jf,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M6.4 20.4q-.5.2-.95-.087T5 19.475V5q0-.825.588-1.413T7 3h6v2H7v12.95l5-2.15l5 2.15V11h2v8.475q0 .55-.45.838t-.95.087L12 18l-5.6 2.4ZM7 5h6h-6Zm11 4q-.425 0-.713-.287T17 8V7h-1q-.425 0-.713-.288T15 6q0-.425.288-.713T16 5h1V4q0-.425.288-.713T18 3q.425 0 .713.288T19 4v1h1q.425 0 .713.288T21 6q0 .425-.288.713T20 7h-1v1q0 .425-.288.713T18 9Z"},null,-1)])])}const Fl=be(Lf,[["render",Bf]]),Nf=Object.freeze(Object.defineProperty({__proto__:null,default:Fl},Symbol.toStringTag,{value:"Module"})),er=ge({__name:"ButtonEntry",props:{entryId:{type:null},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;$t({onKeyUp:i=>{i.key==="t"&&!i.metaKey&&!i.ctrlKey&&n("click")}});function o(){n("click")}return(i,r)=>(v(),ie(Ge,{transparent:e.transparent,title:e.entryId?"View entry (T)":"Add to library (T)","data-tour":"Prress here to add to your library",onClick:o},{default:oe(()=>[e.entryId?(v(),ie(Hl,{key:0})):(v(),ie(Fl,{key:1}))]),_:1},8,["transparent","title"]))}}),Vf=Object.freeze(Object.defineProperty({__proto__:null,default:er},Symbol.toStringTag,{value:"Module"})),Rf={},Hf={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function Ff(e,t){return v(),z("svg",Hf,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M16.5 16V8l-4 4l4 4ZM5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h14q.825 0 1.413.588T21 5v14q0 .825-.588 1.413T19 21H5Zm3-2V5H5v14h3Zm2 0h9V5h-9v14Zm-2 0H5h3Z"},null,-1)])])}const Wl=be(Rf,[["render",Ff]]),Wf=Object.freeze(Object.defineProperty({__proto__:null,default:Wl},Symbol.toStringTag,{value:"Module"})),Go=ge({inheritAttrs:!1,__name:"ButtonHide",props:{transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;return(o,i)=>(v(),ie(Ge,{title:"Hide reader","data-tour":"You have entered reader mode, press here to return to the original page",class:ue(o.$attrs.class),transparent:e.transparent,onClick:i[0]||(i[0]=()=>n("click"))},{default:oe(()=>[V(Wl)]),_:1},8,["class","transparent"]))}}),Uf=Object.freeze(Object.defineProperty({__proto__:null,default:Go},Symbol.toStringTag,{value:"Module"})),qf={},Kf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function Zf(e,t){return v(),z("svg",Kf,[...t[0]||(t[0]=[Y("path",{d:"M199.9 416h-63.8c-4.5 0-8.1-3.6-8.1-8V104c0-4.4 3.6-8 8.1-8h63.8c4.5 0 8.1 3.6 8.1 8v304c0 4.4-3.6 8-8.1 8z",fill:"currentColor"},null,-1),Y("path",{d:"M375.9 416h-63.8c-4.5 0-8.1-3.6-8.1-8V104c0-4.4 3.6-8 8.1-8h63.8c4.5 0 8.1 3.6 8.1 8v304c0 4.4-3.6 8-8.1 8z",fill:"currentColor"},null,-1)])])}const tr=be(qf,[["render",Zf]]),Yf=Object.freeze(Object.defineProperty({__proto__:null,default:tr},Symbol.toStringTag,{value:"Module"})),Xf={},Gf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function Jf(e,t){return v(),z("svg",Gf,[...t[0]||(t[0]=[Y("path",{d:"M128 104.3v303.4c0 6.4 6.5 10.4 11.7 7.2l240.5-151.7c5.1-3.2 5.1-11.1 0-14.3L139.7 97.2c-5.2-3.3-11.7.7-11.7 7.1z",fill:"currentColor"},null,-1)])])}const nr=be(Xf,[["render",Jf]]),Qf=Object.freeze(Object.defineProperty({__proto__:null,default:nr},Symbol.toStringTag,{value:"Module"})),or=ge({inheritAttrs:!1,__name:"ButtonPlay",props:{tourMessage:{type:String},playing:{type:Boolean},disabled:{type:Boolean},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=e,o=t;return $t({onKeyDown(i){!n.disabled&&i.key===" "&&(i.preventDefault(),o("click"))}}),(i,r)=>(v(),ie(Ge,{transparent:e.transparent,class:ue(i.$attrs.class),"data-tour":e.tourMessage,title:`${e.playing?"Pause":"Play"} (Space)`,disabled:e.disabled,onClick:r[0]||(r[0]=()=>o("click"))},{default:oe(()=>[e.playing?(v(),ie(tr,{key:0})):(v(),ie(nr,{key:1}))]),_:1},8,["transparent","class","data-tour","title","disabled"]))}}),ep=Object.freeze(Object.defineProperty({__proto__:null,default:or},Symbol.toStringTag,{value:"Module"})),tp={},np={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"};function op(e,t){return v(),z("svg",np,[...t[0]||(t[0]=[Y("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[Y("circle",{cx:"14",cy:"14",r:"12"}),Y("path",{d:"m23 23l7 7M9 12V9h3m4 0h3v3M9 16v3h3m7-3v3h-3"})],-1)])])}const Ul=be(tp,[["render",op]]),ip=Object.freeze(Object.defineProperty({__proto__:null,default:Ul},Symbol.toStringTag,{value:"Module"})),rp={class:"block w-4 h-4"},sp={class:"w-12"},ql=ge({__name:"ButtonResetZoom",props:{zoom:{type:Number}},emits:["click"],setup(e,{emit:t}){const n=t;function o(i){n("click",i)}return(i,r)=>(v(),z("button",{class:"h-9 rounded-full inline-flex justify-between items-center bg-black bg-opacity-50 gap-1 py-2 px-3 pointer-events-auto hover:bg-stone-900 hover:bg-opacity-50 duration-200",title:"Reset zoom",onClick:Be(o,["stop"])},[Y("div",rp,[V(Ul)]),Y("div",sp,Fe(Math.ceil(e.zoom*100))+"%",1)]))}}),lp=Object.freeze(Object.defineProperty({__proto__:null,default:ql},Symbol.toStringTag,{value:"Module"})),ap={},cp={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 36 36"};function up(e,t){return v(),z("svg",cp,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"m32.57 15.72l-3.35-1a11.65 11.65 0 0 0-.95-2.33l1.64-3.07a.61.61 0 0 0-.11-.72l-2.39-2.4a.61.61 0 0 0-.72-.11l-3.05 1.63a11.62 11.62 0 0 0-2.36-1l-1-3.31a.61.61 0 0 0-.59-.41h-3.38a.61.61 0 0 0-.58.43l-1 3.3a11.63 11.63 0 0 0-2.38 1l-3-1.62a.61.61 0 0 0-.72.11L6.2 8.59a.61.61 0 0 0-.11.72l1.62 3a11.63 11.63 0 0 0-1 2.37l-3.31 1a.61.61 0 0 0-.43.58v3.38a.61.61 0 0 0 .43.58l3.33 1a11.62 11.62 0 0 0 1 2.33l-1.64 3.14a.61.61 0 0 0 .11.72l2.39 2.39a.61.61 0 0 0 .72.11l3.09-1.65a11.65 11.65 0 0 0 2.3.94l1 3.37a.61.61 0 0 0 .58.43h3.38a.61.61 0 0 0 .58-.43l1-3.38a11.63 11.63 0 0 0 2.28-.94l3.11 1.66a.61.61 0 0 0 .72-.11l2.39-2.39a.61.61 0 0 0 .11-.72l-1.66-3.1a11.63 11.63 0 0 0 .95-2.29l3.37-1a.61.61 0 0 0 .43-.58v-3.41a.61.61 0 0 0-.37-.59ZM18 23.5a5.5 5.5 0 1 1 5.5-5.5a5.5 5.5 0 0 1-5.5 5.5Z",class:"clr-i-solid clr-i-solid-path-1"},null,-1),Y("path",{fill:"none",d:"M0 0h36v36H0z"},null,-1)])])}const Kl=be(ap,[["render",up]]),dp=Object.freeze(Object.defineProperty({__proto__:null,default:Kl},Symbol.toStringTag,{value:"Module"})),ir=ge({__name:"ButtonSettings",props:{disabled:{type:Boolean},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;return $t({onKeyUp:o=>{o.key==="s"&&!o.metaKey&&!o.ctrlKey&&n("click")}}),(o,i)=>(v(),ie(Ge,{transparent:e.transparent,title:"Reader preferences (S)",disabled:e.disabled,onClick:i[0]||(i[0]=()=>n("click"))},{default:oe(()=>[V(Kl)]),_:1},8,["transparent","disabled"]))}}),fp=Object.freeze(Object.defineProperty({__proto__:null,default:ir},Symbol.toStringTag,{value:"Module"})),pp={},hp={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function gp(e,t){return v(),z("svg",hp,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M4 4h6v2H6v4H4V4Zm10 0h6v6h-2V6h-4V4ZM6 14v4h4v2H4v-6h2Zm14 0v6h-6v-2h4v-4h2Z"},null,-1)])])}const Zl=be(pp,[["render",gp]]),mp=Object.freeze(Object.defineProperty({__proto__:null,default:Zl},Symbol.toStringTag,{value:"Module"})),vp={},bp={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function yp(e,t){return v(),z("svg",bp,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M14 20v-6h6v2h-4v4h-2Zm-6 0v-4H4v-2h6v6H8Zm12-10h-6V4h2v4h4v2Zm-10 0H4V8h4V4h2v6Z"},null,-1)])])}const Yl=be(vp,[["render",yp]]),wp=Object.freeze(Object.defineProperty({__proto__:null,default:Yl},Symbol.toStringTag,{value:"Module"})),rr=ge({__name:"ButtonWebFullScreen",props:{transparent:{type:Boolean}},emits:["request-full-screen"],setup(e,{emit:t}){const n=t,o=te(!1);$t({onKeyUp:r=>{r.key==="f"&&!r.metaKey&&!r.ctrlKey&&i()}}),_t("fullscreenchange",()=>{o.value=!!document.fullscreenElement});function i(){document.fullscreenElement?document.exitFullscreen():n("request-full-screen")}return(r,s)=>(v(),ie(Ge,{transparent:e.transparent,title:`${o.value?"Exit":"Enter"} fullscreen (F)`,onClick:i},{default:oe(()=>[o.value?(v(),ie(Yl,{key:0})):(v(),ie(Zl,{key:1}))]),_:1},8,["transparent","title"]))}}),xp=Object.freeze(Object.defineProperty({__proto__:null,default:rr},Symbol.toStringTag,{value:"Module"})),_p=["aria-hidden"],Sp=["onClick"],Xl=ge({__name:"DropdownMenu",props:Ye({items:{type:Array},enableHapticFeedback:{type:Boolean}},{modelValue:{type:Number,required:!1},modelModifiers:{}}),emits:Ye(["select"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=st(e,"modelValue"),r=te(null),s=te(!1),l=te(!1),a=te(!1),u=te(!1),c={mounted:b=>{var g;i.value&&((g=b.children[i.value])==null||g.scrollIntoView({behavior:"auto",block:"center",inline:"center"}))}};$t({onKeyDown:$}),Xi(()=>{const b=s.value;return b&&(s.value=!1),b});const d=Yo(),f=Xo();async function h(b){s.value=b??!s.value,d(s.value),s.value?(w(),B(r.value)):setTimeout(A,250)}function w(){const b=r.value;if(b){const g=b.getBoundingClientRect(),E=g.x+g.width/2;l.value=g.y>window.innerHeight/2,a.value=E<window.innerWidth/3,u.value=E>window.innerWidth/3*2}}function y(b,g){h(),b!=i.value&&(i.value=b,o("select",b,g),n.enableHapticFeedback&&f())}function $(b){s.value&&b.key==="Escape"&&(h(),b.preventDefault())}let k=[];function B(b){const g=window.getComputedStyle(b).zIndex,E=b.style.zIndex;(!g||!(+g>0))&&((!b.parentElement||b.parentElement.childElementCount>1)&&(b.style.zIndex="1",k.push({el:b,zIndex:E})),b.parentElement&&B(b.parentElement))}function A(){k.forEach(({el:b,zIndex:g})=>{b.style.zIndex=g??""}),k=[]}return(b,g)=>(v(),z("div",{ref_key:"root",ref:r,class:"select-none relative inline-flex"},[s.value?(v(),z("div",{key:0,class:"fixed inset-0 bg-transparent",onClick:g[0]||(g[0]=()=>h())})):le("",!0),e.items.length?(v(),ie(Gn,{key:1,"enter-from-class":"scale-y-90 opacity-0 pointer-events-none","leave-to-class":"scale-y-90 opacity-0 pointer-events-none"},{default:oe(()=>[s.value?Re((v(),z("ul",{key:0,ref:"list","aria-hidden":!s.value,class:ue(["scrollbar-sm duration-150 delay-50 absolute w-40 max-h-[70vh] list-none bg-stone-800 bg-opacity-80 backdrop-blur-md rounded-lg overflow-auto",{"origin-bottom bottom-full -translate-y-1.5":l.value,"origin-top top-full translate-y-1.5":!l.value,"left-1/2 -ml-20 text-center":!a.value&&!u.value,"right-0 text-right":u.value}]),onWheelPassive:g[1]||(g[1]=Be(()=>{},["stop"])),onTouchmove:g[2]||(g[2]=Be(()=>{},["stop"]))},[(v(!0),z(ye,null,Xt(e.items,(E,L)=>Re((v(),z("li",{key:L,tabindex:"-1",class:ue(["h-10 px-4 last:border-b-transparent cursor-pointer hover:bg-stone-100 hover:bg-opacity-10 duration-100",{"text-textPrimary":L===i.value}]),onClick:Z=>y(L,Z)},[Y("div",{class:ue(["h-full py-2",{"border-t-[1px] border-solid border-stone-400 border-opacity-30":L>0}])},[Se(b.$slots,"item",{item:E},()=>[Wt(Fe(E),1)])],2)],10,Sp)),[[X(zt),30]])),128))],42,_p)),[[c]]):le("",!0)]),_:3})):le("",!0),Se(b.$slots,"default",{toggle:h,isOpen:s.value,isAlignTop:l.value})],512))}}),kp=Object.freeze(Object.defineProperty({__proto__:null,default:Xl},Symbol.toStringTag,{value:"Module"})),Cp={},Tp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Mp(e,t){return v(),z("svg",Tp,[...t[0]||(t[0]=[Au('<circle cx="18" cy="12" r="0" fill="currentColor"><animate attributeName="r" begin=".67" calcMode="spline" dur="1.5s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"></animate></circle><circle cx="12" cy="12" r="0" fill="currentColor"><animate attributeName="r" begin=".33" calcMode="spline" dur="1.5s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"></animate></circle><circle cx="6" cy="12" r="0" fill="currentColor"><animate attributeName="r" begin="0" calcMode="spline" dur="1.5s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"></animate></circle>',3)])])}const Gl=be(Cp,[["render",Mp]]),Pp=Object.freeze(Object.defineProperty({__proto__:null,default:Gl},Symbol.toStringTag,{value:"Module"})),Ep={},Ip={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Op(e,t){return v(),z("svg",Ip,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"m7 10l5 5l5-5z"},null,-1)])])}const Jl=be(Ep,[["render",Op]]),$p=Object.freeze(Object.defineProperty({__proto__:null,default:Jl},Symbol.toStringTag,{value:"Module"})),zp=["onClick"],Dp={class:"inline-flex items-center justify-center w-full h-full px-4 rounded-full group-hover:bg-stone-100 group-hover:bg-opacity-20 duration-200"},Ap={class:"whitespace-nowrap"},sr=ge({inheritAttrs:!1,__name:"ButtonDropdown",props:Ye({label:{type:String},title:{type:String},items:{type:Array},disabled:{type:Boolean},canLoadItems:{type:Boolean},loadItems:{type:Function},enableHapticFeedback:{type:Boolean},transparent:{type:Boolean}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:Ye(["select"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=st(e,"modelValue"),r=te(!1),s=Yo();async function l(f,h){if(!n.items.length&&(f||await a(),!n.items.length)){h(!1);return}h()}async function a(){r.value||n.items.length||!n.canLoadItems||!n.loadItems||(r.value=!0,await n.loadItems(),r.value=!1)}let u=!1;function c(){u||(u=!0,s(!0,{desktopOnly:!0}))}function d(){u&&(u=!1,s(!1,{desktopOnly:!0}))}return(f,h)=>(v(),ie(Xl,{modelValue:i.value,"onUpdate:modelValue":h[0]||(h[0]=w=>i.value=w),items:e.items,class:ue(f.$attrs.class),"enable-haptic-feedback":e.enableHapticFeedback,onSelect:h[1]||(h[1]=(w,y)=>o("select",w,y))},Ei({default:oe(({toggle:w,isOpen:y,isAlignTop:$})=>[Re((v(),z("button",kn({type:"button",tabindex:"-1",class:["w-full h-10 max-h-full rounded-full group duration-100 transition-bg",{"pointer-events-none opacity-60":e.disabled||r.value,"bg-black bg-opacity-50":!e.transparent,"bg-transparent":e.transparent}]},e.title?{title:e.title}:{},{onClick:Be(()=>l(y,w),["stop"]),onMouseenter:c,onMouseleave:d}),[Y("div",Dp,[Y("span",Ap,Fe(e.label),1),e.items.length||e.canLoadItems?(v(),z("span",{key:0,class:ue(["w-4 h-4 flex ml-1 -mr-3 flex-shrink-0",{"rotate-180":$}]),"aria-hidden":"true"},[r.value?(v(),ie(Gl,{key:0})):(v(),ie(Jl,{key:1}))],2)):le("",!0)])],16,zp)),[[X(zt),30]])]),_:2},[f.$slots.item?{name:"item",fn:oe(({item:w})=>[Se(f.$slots,"item",{item:w})]),key:"0"}:void 0]),1032,["modelValue","items","class","enable-haptic-feedback"]))}}),Lp=Object.freeze(Object.defineProperty({__proto__:null,default:sr},Symbol.toStringTag,{value:"Module"})),jp={},Bp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Np(e,t){return v(),z("svg",Bp,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M15.41 7.41L14 6l-6 6l6 6l1.41-1.41L10.83 12z"},null,-1)])])}const Ql=be(jp,[["render",Np]]),Vp=Object.freeze(Object.defineProperty({__proto__:null,default:Ql},Symbol.toStringTag,{value:"Module"})),Rp={},Hp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Fp(e,t){return v(),z("svg",Hp,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M10 6L8.59 7.41L13.17 12l-4.58 4.59L10 18l6-6z"},null,-1)])])}const ea=be(Rp,[["render",Fp]]),Wp=Object.freeze(Object.defineProperty({__proto__:null,default:ea},Symbol.toStringTag,{value:"Module"})),Up={key:0,class:"ml-auto inline-flex gap-[1px] scale-95 origin-right"},lr=ge({__name:"ChapterNav",props:{data:{type:Object},chapterSpec:{type:[Object,String]},touchDevice:{type:Boolean},rtl:{type:Boolean},transparent:{type:Boolean}},emits:["getHiddenChapters","prev","next","dialogOpened"],setup(e,{emit:t}){const n=e,o=t,i=Q(()=>{var d;return typeof n.chapterSpec!="string"&&!!((d=n.chapterSpec)!=null&&d.trigger)});async function r(){const d=typeof n.chapterSpec=="string"?{sel:n.chapterSpec}:n.chapterSpec;if(!d)return;const{trigger:f,sel:h,label:w}=d;if(f&&(h===void 0||!w)){await s(f);return}o("getHiddenChapters"),await en(50,50,()=>n.data.chapters.length?!0:void 0)}async function s(d){const f=document.querySelector(d);f&&(f instanceof HTMLDialogElement?f.showModal():f.click(),o("dialogOpened"))}function l(d,f){var h,w,y;(y=(w=(h=n.data)==null?void 0:h.chapters)==null?void 0:w[d])==null||y.select(c(f))}function a(d){n.rtl?o("next",c(d)):o("prev",c(d))}function u(d){n.rtl?o("prev",c(d)):o("next",c(d))}function c(d){return!n.touchDevice&&(d.ctrlKey||d.metaKey)}return(d,f)=>(v(),z(ye,null,[V(sr,{modelValue:e.data.activeIndex,label:e.data.activeLabel,title:"Select chapter",transparent:e.transparent,items:e.data.chapters,"can-load-items":i.value,"load-items":r,"enable-haptic-feedback":"",onSelect:l},{item:oe(({item:h})=>[Wt(Fe(h.label),1)]),_:1},8,["modelValue","label","transparent","items","can-load-items"]),e.data.next||e.data.prev?(v(),z("div",Up,[V(Ge,{title:`${e.rtl?"Next":"Prev"} chapter (←)`,disabled:e.rtl?!e.data.next:!e.data.prev,transparent:e.transparent,class:"!rounded-r-none","enable-haptic-feedback":"",onClick:a},{default:oe(()=>[V(Ql)]),_:1},8,["title","disabled","transparent"]),V(Ge,{title:`${e.rtl?"Prev":"Next"} chapter (→)`,disabled:e.rtl?!e.data.prev:!e.data.next,transparent:e.transparent,class:"!rounded-l-none","enable-haptic-feedback":"",onClick:u},{default:oe(()=>[V(ea)]),_:1},8,["title","disabled","transparent"])])):le("",!0)],64))}}),qp=Object.freeze(Object.defineProperty({__proto__:null,default:lr},Symbol.toStringTag,{value:"Module"})),Kp=["min","max","step"],Zp={class:"flex-shrink-0 w-12 inline-block text-right"},tn=be(ge({__name:"InputPercentage",props:Ye({min:{type:Number},max:{type:Number},step:{type:Number},format:{type:Function}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=st(e,"modelValue"),n=Q({get(){return t.value},set(o){t.value=+o}});return(o,i)=>{var r;return v(),z("div",{class:"flex items-center gap-3 pl-1",style:Ce({"--percentage":`${(n.value-e.min)/(e.max-e.min)*100}%`})},[Re(Y("input",{"onUpdate:modelValue":i[0]||(i[0]=s=>n.value=s),type:"range",min:e.min,max:e.max,step:e.step??1,class:"flex-grow",onTouchmove:i[1]||(i[1]=Be(()=>{},["stop"]))},null,40,Kp),[[yd,n.value]]),Y("span",Zp,Fe(((r=e.format)==null?void 0:r.call(e,t.value))??t.value),1)],4)}}}),[["styles",["input[type=range]{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:linear-gradient(to right,#fb8252 var(--percentage),#5a5552 var(--percentage));border-radius:9999px;border-style:none;cursor:pointer;height:4px;opacity:.9;pointer-events:none;--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1));outline:2px solid transparent;outline-offset:2px}input[type=range]::-webkit-slider-thumb{-webkit-appearance:none!important;border-radius:9999px;border-style:solid;border-width:2px;cursor:pointer;height:24px;pointer-events:auto;width:24px;--tw-border-opacity:1;border-color:rgb(251 130 82/var(--tw-border-opacity,1));--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1));transition-duration:.2s}input[type=range]:hover{opacity:1}"]]]),Yp=Object.freeze(Object.defineProperty({__proto__:null,default:tn},Symbol.toStringTag,{value:"Module"})),Xp={ref:"root",class:"flex text-sm flex-wrap gap-2 leading-none"},Gp=["onClick","onKeyup"],mt=ge({__name:"InputSelect",props:Ye({items:{type:Array}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=st(e,"modelValue");function o(i){i!==n.value&&(n.value=i)}return(i,r)=>(v(),z("div",Xp,[(v(!0),z(ye,null,Xt(t.items,(s,l)=>Re((v(),z("div",{key:l,tabindex:"0",class:ue(["inline-flex justify-center items-center rounded-full px-3 py-1.5 cursor-pointer z-10 whitespace-nowrap flex-shrink-0 focus:outline-primary hover:bg-opacity-80 duration-200",{"bg-primary":l==n.value,"bg-stone-600 bg-opacity-50":l!=n.value}]),onClick:()=>o(l),onKeyup:[qo(()=>o(l),["enter"]),qo(()=>o(l),["space"])]},[Wt(Fe(s),1)],42,Gp)),[[X(zt),30]])),128))],512))}}),Jp=Object.freeze(Object.defineProperty({__proto__:null,default:mt},Symbol.toStringTag,{value:"Module"})),Qp={class:"flex w-full items-center justify-between cursor-pointer mb-5 last:mb-0"},eh={class:"text-sm py-1"},th={class:"switcher p-1"},ar=be(ge({__name:"InputSwitcher",props:Ye({label:{type:String}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=st(e,"modelValue");return(n,o)=>(v(),z("label",Qp,[Y("span",eh,Fe(e.label),1),Y("div",th,[Re(Y("input",{"onUpdate:modelValue":o[0]||(o[0]=i=>t.value=i),type:"checkbox"},null,512),[[wd,t.value]]),o[1]||(o[1]=Y("span",null,null,-1))])]))}}),[["styles",['.switcher{height:24px;position:relative;width:40px}.switcher input{height:0;opacity:0;width:0}.switcher input:checked+span{border-width:1px;--tw-border-opacity:1;border-color:rgb(184 92 56/var(--tw-border-opacity,1));--tw-bg-opacity:1;background-color:rgb(184 92 56/var(--tw-bg-opacity,1))}.switcher input:checked+span:before{bottom:2px;height:18px;left:17.2px;width:18px}.switcher span{border-radius:9999px;border-width:2px;top:0;right:0;bottom:0;left:0;--tw-border-opacity:1;background-color:transparent;border-color:rgb(231 229 228/var(--tw-border-opacity,1))}.switcher span,.switcher span:before{position:absolute;transition-duration:.3s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.switcher span:before{border-radius:9999px;bottom:4px;content:"";height:12px;left:4px;width:12px;--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}']]]),nh=Object.freeze(Object.defineProperty({__proto__:null,default:ar},Symbol.toStringTag,{value:"Module"})),oh={class:"flex-grow mb-5 last:mb-0"},Le=ge({__name:"TableField",props:{label:{type:String},disabled:{type:Boolean}},setup(e){return(t,n)=>(v(),z(ye,null,[Y("div",{class:ue(["flex-shrink-0 mb-2 whitespace-nowrap text-sm",{"opacity-50":e.disabled}])},Fe(e.label),3),Y("div",oh,[Se(t.$slots,"default")])],64))}}),ih=Object.freeze(Object.defineProperty({__proto__:null,default:Le},Symbol.toStringTag,{value:"Module"})),ta=ge({__name:"FieldContrast",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=st(e,"modelValue"),n=Q({get(){return Math.round(t.value*100)},set(o){t.value=Math.round(o)/100}});return(o,i)=>(v(),ie(Le,{label:"Contrast"},{default:oe(()=>[V(tn,{modelValue:n.value,"onUpdate:modelValue":i[0]||(i[0]=r=>n.value=r),min:20,max:100,format:r=>`${r}%`},null,8,["modelValue","format"])]),_:1}))}}),rh=Object.freeze(Object.defineProperty({__proto__:null,default:ta},Symbol.toStringTag,{value:"Module"})),sh={},lh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function ah(e,t){return v(),z("svg",lh,[...t[0]||(t[0]=[Y("path",{d:"M480 358.856V153.143C480 130.512 461.674 112 439.272 112H72.728C50.326 112 32 130.512 32 153.143v205.713C32 381.488 50.326 400 72.728 400h366.545C461.674 400 480 381.488 480 358.856zM112 364V148h288v216H112z",fill:"currentColor"},null,-1)])])}const na=be(sh,[["render",ah]]),ch=Object.freeze(Object.defineProperty({__proto__:null,default:na},Symbol.toStringTag,{value:"Module"})),uh={},dh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function fh(e,t){return v(),z("svg",dh,[...t[0]||(t[0]=[Y("path",{d:"M358.856 32H153.143C130.512 32 112 50.326 112 72.728v366.545C112 461.674 130.512 480 153.143 480h205.713C381.488 480 400 461.674 400 439.272V72.728C400 50.326 381.488 32 358.856 32zM364 400H148V112h216v288z",fill:"currentColor"},null,-1)])])}const oa=be(uh,[["render",fh]]),ph=Object.freeze(Object.defineProperty({__proto__:null,default:oa},Symbol.toStringTag,{value:"Module"})),cr=ge({inheritAttrs:!1,__name:"ButtonOutline",emits:["click"],setup(e,{emit:t}){const n=t,o=Xo();function i(){o(),n("click")}return(r,s)=>Re((v(),z("button",{class:ue([r.$attrs.class??"","flex focus:outline-none outline-none rounded-full h-10 justify-center items-center border border-solid border-stone-600 text-stone-200 hover:bg-stone-500 hover:bg-opacity-10 duration-200"]),onClick:i},[Se(r.$slots,"default")],2)),[[X(zt),24]])}}),hh=Object.freeze(Object.defineProperty({__proto__:null,default:cr},Symbol.toStringTag,{value:"Module"}));var nn=(e=>(e[e.never=0]="never",e[e.move=1]="move",e[e.firstMove=2]="firstMove",e[e.onLoad=3]="onLoad",e))(nn||{}),tt=(e=>(e[e.vertical=0]="vertical",e[e.ltr=1]="ltr",e[e.rtl=2]="rtl",e))(tt||{});const Jo=[{name:"System",value:"system-ui, sans-serif"},{name:"Charter",value:'Charter, "Times New Roman", serif'},{name:"Georgia",value:"Georgia, serif"}],ia=ge({__name:"FieldFontFamily",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=st(e,"modelValue"),n=Q({get(){const o=Jo.findIndex(i=>i.value===t.value);return o===-1?0:o},set(o){t.value=Jo[o].value}});return(o,i)=>(v(),ie(Le,{label:"Font family"},{default:oe(()=>[V(mt,{modelValue:n.value,"onUpdate:modelValue":i[0]||(i[0]=r=>n.value=r),items:X(Jo).map(r=>r.name)},null,8,["modelValue","items"])]),_:1}))}}),gh=Object.freeze(Object.defineProperty({__proto__:null,default:ia},Symbol.toStringTag,{value:"Module"}));function mh(e){if(e)try{return JSON.parse(e)}catch{return}}function vh(){const{width:e,height:t}=mn();return Q(()=>e.value>t.value)}function ra(e){return String(e).normalize("NFKD").replace(/[\u0300-\u036f]/g,"").trim().toLowerCase().replace(/[^a-z0-9 -]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-")}var Dt=(e=>(e[e.longStrip=0]="longStrip",e[e.single=1]="single",e[e.double=2]="double",e))(Dt||{});const Qo=.25,ei=5,ur=.25,ti=.2,ni=5,bh=.05,yh=0,wh=5;function xh(e){var g,E,L,Z,_,O;const n=e.touchDevice&&(window.innerHeight<=600||window.innerWidth<=600)?vh():void 0,{titleName:o,isWebtoon:i}=e,r=o?ra(o):location.hostname,s=te(_h(`tkr:${r}`)),l=j=>{s.value=j;const M=`tkr:${r}`;!j||!Object.keys(j).length?localStorage.removeItem(M):localStorage.setItem(M,JSON.stringify(j))},a=j=>{if(!s.value){l(j);return}const M={...s.value};Object.entries(j).forEach(([G,C])=>{C===void 0?delete M[G]:M[G]=C}),l(M)},u=te((g=s.value)==null?void 0:g.style),c=te((E=s.value)==null?void 0:E.direction),d=te((L=s.value)==null?void 0:L.gap),f=te((Z=s.value)==null?void 0:Z.speed),h=te((_=s.value)==null?void 0:_.zoom),w=te(((O=s.value)==null?void 0:O.breakFirst)??!1),y=Q({get(){if(i.value)return Dt.longStrip;if(u.value!==void 0)return u.value;const{landscapeStyle:j,readerStyle:M}=e.defaultPreferences.value;return n!=null&&n.value?j??M:M},set:j=>{if(u.value===j)return;const M=y.value===Dt.longStrip,G=j===Dt.longStrip;u.value=j,a({style:j}),M!==G&&($.value=G?tt.vertical:tt.rtl)}}),$=Q({get(){if(i.value)return tt.vertical;if(c.value!==void 0)return c.value;const{direction:j,landscapeDirection:M}=e.defaultPreferences.value;return n!=null&&n.value?M??j:j},set:j=>{c.value=j,a({direction:j})}}),k=Q({get:()=>d.value??e.defaultPreferences.value.gap,set(j){d.value=j,a({gap:j})}}),B=Q({get:()=>f.value??e.defaultPreferences.value.speed,set(j){f.value=j,a({speed:j===1?void 0:j})}}),A=Q({get:()=>h.value??1,set(j){h.value=j,a({zoom:j===1?void 0:j})}}),b=Q({get:()=>w.value,set(j){w.value=j,a({breakFirst:j?!0:void 0})}});return{direction:$,style:y,gap:k,speed:B,zoom:A,isLongStrip:Q(()=>y.value===Dt.longStrip),isDouble:Q(()=>y.value===Dt.double),isRTL:Q(()=>$.value===tt.rtl),isVertical:Q(()=>$.value===tt.vertical),breakFirst:b}}function _h(e){const t=localStorage.getItem(e),n=mh(t||void 0),o={};return n?(n.style!==void 0&&Object.values(Dt).includes(n.style)&&(o.style=n.style),n.direction!==void 0&&Object.values(tt).includes(n.direction)&&(o.direction=n.direction),n.gap!==void 0&&n.gap>=yh&&n.gap<=wh&&(o.gap=n.gap),n.speed!==void 0&&n.speed>=Qo&&n.speed<=ei&&(o.speed=n.speed),n.zoom!==void 0&&n.zoom>=ti&&n.zoom<=ni&&(o.zoom=n.zoom),n.breakFirst===!0&&(o.breakFirst=!0),Object.keys(o).length?o:void 0):o}const dr=ge({__name:"NovelPreferencesForm",props:Ye({enableReset:{type:Boolean},defaultPreferences:{type:Object}},{modelValue:{required:!0},modelModifiers:{}}),emits:Ye(["reset"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=st(e,"modelValue"),r=Q(()=>Object.keys(i.value).some(l=>{var a;return i.value[l]!==((a=n.defaultPreferences)==null?void 0:a[l])}));function s(l){i.value={...i.value,...l}}return(l,a)=>(v(),z(ye,null,[V(ia,{"model-value":i.value.fontFamily,"onUpdate:modelValue":a[0]||(a[0]=u=>s({fontFamily:u}))},null,8,["model-value"]),V(Le,{label:"Text size"},{default:oe(()=>[V(tn,{"model-value":i.value.fontSize,min:10,max:48,"onUpdate:modelValue":a[1]||(a[1]=u=>s({fontSize:u,lineHeight:Math.max(i.value.lineHeight,u)}))},null,8,["model-value"])]),_:1}),V(Le,{label:"Line height"},{default:oe(()=>[V(tn,{"model-value":i.value.lineHeight,min:10,max:96,step:1,"onUpdate:modelValue":a[2]||(a[2]=u=>s({lineHeight:u,fontSize:Math.min(i.value.fontSize,u)}))},null,8,["model-value"])]),_:1}),V(Le,{label:"Play speed"},{default:oe(()=>[V(tn,{"model-value":i.value.speed,min:X(Qo),max:X(ei),step:X(ur),format:u=>`${u.toFixed(2)}x`,"onUpdate:modelValue":a[3]||(a[3]=u=>s({speed:u}))},null,8,["model-value","min","max","step","format"])]),_:1}),e.enableReset?(v(),z("div",{key:0,class:ue(["w-full flex justify-center pt-1 duration-200",{"pointer-events-none opacity-0":!r.value,"opacity-90":r.value}])},[V(cr,{class:"w-2/3",onClick:a[4]||(a[4]=()=>o("reset"))},{default:oe(()=>[...a[5]||(a[5]=[Wt(" Reset to default ",-1)])]),_:1})],2)):le("",!0)],64))}}),Sh=Object.freeze(Object.defineProperty({__proto__:null,default:dr},Symbol.toStringTag,{value:"Module"})),kh={key:1,class:"mb-3 border-stone-500 border-opacity-70"},Ch={key:2,class:"flex justify-end"},Th={class:"h-6 border border-stone-500 rounded-md cursor-pointer flex items-center"},Mh={key:3,class:"mt-5 mb-3 border-stone-500 border-opacity-70"},fr=ge({__name:"DefaultPreferencesForm",props:Ye({touchDevice:{type:Boolean},isNovel:{type:Boolean}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=st(e,"modelValue"),o=te(!1),i=te(!1);je(()=>{o.value=t.touchDevice&&(window.innerHeight<=600||window.innerWidth<=600)});function r(l){const a=i.value,c=(a?n.value.landscapeStyle??n.value.readerStyle:n.value.readerStyle)!==Dt.longStrip,d=l!==Dt.longStrip;if(c===d)s(a?{landscapeStyle:l}:{readerStyle:l});else{const f=d?tt.rtl:tt.vertical;s(a?{landscapeStyle:l,landscapeDirection:f}:{readerStyle:l,direction:f})}}function s(l){n.value={...n.value,...l}}return(l,a)=>(v(),z(ye,null,[e.isNovel?(v(),z(ye,{key:0},[V(dr,{modelValue:n.value,"onUpdate:modelValue":a[0]||(a[0]=u=>n.value=u)},null,8,["modelValue"]),V(ta,{"model-value":n.value.contrast,"onUpdate:modelValue":a[1]||(a[1]=u=>s({contrast:u}))},null,8,["model-value"])],64)):(v(),z(ye,{key:1},[V(ar,{"model-value":n.value.autoPlay===!0,label:"Auto play in long strip","onUpdate:modelValue":a[2]||(a[2]=u=>s({autoPlay:u}))},null,8,["model-value"]),e.touchDevice?(v(),ie(ar,{key:0,"model-value":n.value.pinchToZoom!==!1,label:"Pinch to zoom","onUpdate:modelValue":a[3]||(a[3]=u=>s({pinchToZoom:u}))},null,8,["model-value"])):le("",!0),o.value?(v(),z("hr",kh)):le("",!0),o.value?(v(),z("div",Ch,[Y("div",Th,[Re((v(),z("button",{class:ue(["focus:outline-none outline-none h-full flex justify-center items-center px-3 py-0.5 rounded-l-sm",{"bg-stone-500 text-stone-50":!i.value,"text-stone-400":i.value}]),onClick:a[4]||(a[4]=()=>i.value=!1)},[V(oa)],2)),[[X(zt),24]]),Re((v(),z("button",{class:ue(["focus:outline-none outline-none h-full flex justify-center items-center px-3 py-0.5 rounded-r-sm",{"bg-stone-500 text-stone-50":i.value,"text-stone-400":!i.value}]),onClick:a[5]||(a[5]=()=>i.value=!0)},[V(na)],2)),[[X(zt),24]])])])):le("",!0),V(Le,{label:"Style"},{default:oe(()=>[V(mt,{"model-value":i.value?n.value.landscapeStyle??n.value.readerStyle:n.value.readerStyle,items:["Long strip","Single page","Double page"],"onUpdate:modelValue":r},null,8,["model-value"])]),_:1}),V(Le,{label:"Direction"},{default:oe(()=>[V(mt,{"model-value":i.value?n.value.landscapeDirection??n.value.direction:n.value.direction,items:["Vertical","Left to right","Right to left"],"onUpdate:modelValue":a[6]||(a[6]=u=>s(i.value?{landscapeDirection:u}:{direction:u}))},null,8,["model-value"])]),_:1}),o.value?(v(),z("hr",Mh)):le("",!0),V(Le,{label:"Gap size"},{default:oe(()=>[V(mt,{"model-value":n.value.gap,items:["None","1px","2px","3px","4px","5px"],"onUpdate:modelValue":a[7]||(a[7]=u=>s({gap:u}))},null,8,["model-value"])]),_:1})],64)),V(Le,{label:"Progress size"},{default:oe(()=>[V(mt,{"model-value":n.value.progressSize/2,items:["None","2px","4px","6px","8px","10px"],"onUpdate:modelValue":a[8]||(a[8]=u=>s({progressSize:u*2}))},null,8,["model-value"])]),_:1}),V(Le,{label:"Auto next"},{default:oe(()=>[V(mt,{"model-value":n.value.autoNextSeconds,items:["None","1 sec","2 sec","3 sec","4 sec","5 sec"],"onUpdate:modelValue":a[9]||(a[9]=u=>s({autoNextSeconds:u}))},null,8,["model-value"])]),_:1}),V(Le,{label:"Hide controls"},{default:oe(()=>[V(mt,{"model-value":n.value.hideControlsEvent,items:["Never","On move","On first move","On load"],"onUpdate:modelValue":a[10]||(a[10]=u=>s({hideControlsEvent:u}))},null,8,["model-value"])]),_:1}),e.isNovel?le("",!0):(v(),z(ye,{key:2},[V(Le,{label:"Play speed"},{default:oe(()=>[V(tn,{"model-value":n.value.speed,min:X(Qo),max:X(ei),step:X(ur),format:u=>`${u.toFixed(2)}x`,"onUpdate:modelValue":a[11]||(a[11]=u=>s({speed:u}))},null,8,["model-value","min","max","step","format"])]),_:1}),V(Le,{label:e.touchDevice?"Tap zones":"Click zones"},{default:oe(()=>[V(mt,{"model-value":(n.value.tapZone??-1)+1,items:["Default","None","L shaped","Kindle-ish","Edge","Right and left"],"onUpdate:modelValue":a[12]||(a[12]=u=>s({tapZone:u===0?void 0:u-1}))},null,8,["model-value"])]),_:1},8,["label"])],64))],64))}}),Ph=Object.freeze(Object.defineProperty({__proto__:null,default:fr},Symbol.toStringTag,{value:"Module"})),Eh={},Ih={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Oh(e,t){return v(),z("svg",Ih,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M11.3 19.3q-.275-.275-.288-.7t.263-.7l4.9-4.9H5q-.425 0-.713-.288T4 12q0-.425.288-.713T5 11h11.175l-4.9-4.9q-.275-.275-.263-.7t.288-.7q.275-.275.7-.275t.7.275l6.6 6.6q.15.125.213.313t.062.387q0 .2-.062.375t-.213.325l-6.6 6.6q-.275.275-.7.275t-.7-.275Z"},null,-1)])])}const no=be(Eh,[["render",Oh]]),$h=Object.freeze(Object.defineProperty({__proto__:null,default:no},Symbol.toStringTag,{value:"Module"}));var pr=(e=>(e[e.none=0]="none",e[e.lShape=1]="lShape",e[e.kindleIsh=2]="kindleIsh",e[e.edge=3]="edge",e[e.rightAndLeft=4]="rightAndLeft",e))(pr||{});const sa={0:{prevZones:[],nextZones:[]},1:{prevZones:[0,1,2,3],nextZones:[8,7,6,5]},2:{prevZones:[6,3],nextZones:[8,7,5,4]},3:{prevZones:[7],nextZones:[5,0,2,3,6,8]},4:{prevZones:[3,0,6],nextZones:[5,2,8]}},la=ge({__name:"TapZonePreview",props:{tapZone:{type:Number},direction:{type:Number}},setup(e){const t=e,{width:n,height:o}=mn(),i=Q(()=>Math.min(1.25,Math.max(.75,Math.round(n.value/o.value*100)/100))),r=Q(()=>i.value>=1),s=Q(()=>t.direction===tt.vertical),l=Q(()=>t.direction===tt.rtl),a=Q(()=>{if(!t.tapZone)return;const{prevZones:u,nextZones:c}=sa[t.tapZone];return Array.from({length:9},(d,f)=>{const h=u.includes(f),w=!h&&c.includes(f);return{isPrev:h,isNext:w,hasArrow:f===u[0]||f===c[0]}})});return(u,c)=>(v(),z("div",{class:ue(["p-2 bg-black bg-opacity-40 rounded-2xl",{"w-28":r.value,"h-28":!r.value}]),style:Ce({"aspect-ratio":i.value})},[e.tapZone===X(pr).none?(v(),z("div",{key:0,class:ue(["inline-block absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 w-14 h-14",{"rotate-90":e.direction===X(tt).vertical,"rotate-180":e.direction===X(tt).rtl}])},[V(no)],2)):a.value?(v(),z("div",{key:2,class:ue(["w-full h-full overflow-hidden rounded-xl flex flex-wrap",{"flex-row-reverse":l.value}])},[(v(!0),z(ye,null,Xt(a.value,(d,f)=>(v(),z("div",{key:`zone-${f}`,class:ue(["w-1/3 h-1/3 flex justify-center items-center p-0.5",{"bg-stone-100":d.isPrev||d.isNext,"bg-opacity-50":d.isPrev}])},[d.hasArrow?(v(),z("span",{key:0,class:"w-5 h-5 max-w-full max-h-full inline-block transform text-stone-800",style:Ce({transform:`rotate(${s.value?d.isNext?90:-90:(l.value?d.isPrev:d.isNext)?0:180}deg)`})},[V(no)],4)):le("",!0)],2))),128))],2)):(v(),z("div",{key:1,class:ue(["w-full h-full overflow-hidden rounded-xl flex flex-nowrap",{"flex-col":s.value}])},[Y("div",{class:ue(["flex-grow w-full h-full flex justify-center items-center bg-stone-100",{"bg-opacity-50":!l.value}])},[Y("span",{class:ue(["w-5 h-5 inline-block transform text-stone-800",{"-rotate-90":s.value,"rotate-180":!s.value}])},[V(no)],2)],2),c[0]||(c[0]=Y("div",{class:"flex-grow w-full h-full"},null,-1)),c[1]||(c[1]=Y("div",{class:"flex-grow w-full h-full"},null,-1)),Y("div",{class:ue(["flex-grow w-full h-full flex justify-center items-center bg-stone-100",{"bg-opacity-50":l.value}])},[Y("span",{class:ue(["w-5 h-5 inline-block text-stone-800",{"transform rotate-90":s.value}])},[V(no)],2)],2)],2))],6))}}),zh=Object.freeze(Object.defineProperty({__proto__:null,default:la},Symbol.toStringTag,{value:"Module"})),Dh={key:0,class:"inline-block fixed z-50 left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 pointer-events-none duration-200"},aa=ge({__name:"DirectionToast",props:{direction:{type:Number},tapZone:{type:Number}},setup(e){const t=e,n=sessionStorage.getItem("tk:dir"),o=te(typeof n!="string"||+n!==t.direction),i=gt(()=>o.value=!1,1500);de(()=>[t.direction,t.tapZone],()=>{r(),o.value=!0,i()}),je(()=>{r(),i();let s;de(Yi(),a=>{a!=="visible"?s=Date.now():Date.now()-s>7e3&&(o.value=!0,i())})});function r(){sessionStorage.setItem("tk:dir",t.direction+"")}return(s,l)=>(v(),ie(Gn,{"enter-from-class":"opacity-0","leave-to-class":"opacity-0"},{default:oe(()=>[o.value?(v(),z("div",Dh,[V(la,{direction:e.direction,"tap-zone":e.tapZone},null,8,["direction","tap-zone"])])):le("",!0)]),_:1}))}}),Ah=Object.freeze(Object.defineProperty({__proto__:null,default:aa},Symbol.toStringTag,{value:"Module"})),Lh={class:"flex justify-between items-end"},jh={class:"fixed pointer-events-none left-0 right-0 bottom-0"},ca=ge({__name:"GearControlsLayout",props:{visible:{type:Boolean},spaceTop:{type:null}},setup(e){return(t,n)=>(v(),z("div",{id:"controls",class:ue(["fixed pointer-events-none cursor-auto left-0 top-0 w-full h-full flex flex-col justify-between p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3 z-20",{"opacity-100 z-20":e.visible,"opacity-0 -z-10":!e.visible}])},[Se(t.$slots,"default"),Y("div",{class:ue(["flex gap-1 items-center relative z-30 flex-shrink-0 2xs:gap-3",{"children-pointer-events-auto":e.visible}]),style:Ce({paddingTop:`${e.spaceTop||0}px`})},[Se(t.$slots,"top")],6),Y("div",Lh,[Y("div",{class:ue(["inline-block",{"children-pointer-events-auto":e.visible}])},[Se(t.$slots,"bottom-left")],2),Y("div",{class:ue(["inline-flex flex-col items-end gap-4",{"children-pointer-events-auto":e.visible}])},[Se(t.$slots,"bottom-right")],2)]),Y("div",jh,[Se(t.$slots,"progress")])],2))}}),Bh=Object.freeze(Object.defineProperty({__proto__:null,default:ca},Symbol.toStringTag,{value:"Module"})),Nh='.loading-indicator{display:inline-block;height:80px;position:relative;width:80px}.loading-indicator:after,.loading-indicator:before{border-radius:9999px;border-style:solid;border-width:4px;box-sizing:border-box;display:block;position:absolute;--tw-border-opacity:1;animation:lds-ripple 1s cubic-bezier(0,.2,.8,1) infinite;border-color:rgb(184 92 56/var(--tw-border-opacity,1));content:"";opacity:1}.loading-indicator:after{animation-delay:-.5s}@keyframes lds-ripple{0%{height:0;left:40px;opacity:0;top:40px;width:0}4.9%{height:8px;left:36px;opacity:0;top:36px;width:8px}5%{height:8px;left:36px;opacity:1;top:36px;width:8px}to{height:80px;left:0;opacity:0;top:0;width:80px}}',Vh={},Rh={class:"loading-indicator"};function Hh(e,t){return v(),z("div",Rh)}const oi=be(Vh,[["render",Hh],["styles",[Nh]]]),Fh=Object.freeze(Object.defineProperty({__proto__:null,default:oi},Symbol.toStringTag,{value:"Module"})),Wh={class:"max-h-none max-w-none h-full w-full m-0 p-0 border-none outline-none"},Uh={key:0,class:"fixed inset-0 h-[101%] flex justify-center items-center z-10 bg-black"},hr=be(ge({inheritAttrs:!1,__name:"GearLayout",props:{loading:{type:Boolean},immediate:{type:Boolean},hideCursor:{type:Boolean},style:{type:Object}},setup(e,{expose:t}){const n={mounted:i=>i.isConnected&&!i.open&&i.showModal(),beforeUnmount:i=>i.isConnected&&i.open&&i.close()},o=te(null);return t({rootEl:o}),(i,r)=>Re((v(),z("dialog",Wh,[Y("div",{ref_key:"rootEl",ref:o,id:"gear-layout",class:ue({"cursor-none":e.hideCursor,"cursor-default":!e.hideCursor,"bg-black":e.immediate||!e.loading,"opacity-0":!e.immediate&&e.loading,"duration-200 transition-colors":!e.immediate,[`${i.$attrs.class??""}`]:!0}),style:Ce(e.style??{})},[e.loading&&e.immediate?(v(),z("div",Uh,[V(oi)])):le("",!0),Se(i.$slots,"default")],6)])),[[n]])}}),[["styles",["#gear-layout{direction:ltr;font-family:Helvetica,sans-serif;font-size:16px;font-weight:400;height:100%;line-height:24px;overflow:hidden;overscroll-behavior:contain;pointer-events:auto;text-align:left;width:100%}"]]]),qh=Object.freeze(Object.defineProperty({__proto__:null,default:hr},Symbol.toStringTag,{value:"Module"})),Kh={},Zh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 56 56"};function Yh(e,t){return v(),z("svg",Zh,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M29.84 49.574h12.398c4.899 0 7.336-2.437 7.336-7.265V13.69c0-4.828-2.437-7.265-7.336-7.265H29.84Zm-16.055 0h12.398V6.426H13.785c-4.875 0-7.36 2.414-7.36 7.265V42.31c0 4.851 2.485 7.265 7.36 7.265"},null,-1)])])}const ua=be(Kh,[["render",Yh]]),Xh=Object.freeze(Object.defineProperty({__proto__:null,default:ua},Symbol.toStringTag,{value:"Module"})),Gh={},Jh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Qh(e,t){return v(),z("svg",Jh,[...t[0]||(t[0]=[Y("g",{fill:"none"},[Y("path",{d:"M24 0v24H0V0zM12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035c-.01-.004-.019-.001-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427c-.002-.01-.009-.017-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093c.012.004.023 0 .029-.008l.004-.014l-.034-.614c-.003-.012-.01-.02-.02-.022m-.715.002a.023.023 0 0 0-.027.006l-.006.014l-.034.614c0 .012.007.02.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z"}),Y("path",{fill:"currentColor",d:"M8 3v18H5a2 2 0 0 1-1.995-1.85L3 19V5a2 2 0 0 1 1.85-1.995L5 3zm11 0a2 2 0 0 1 1.995 1.85L21 5v14a2 2 0 0 1-1.85 1.995L19 21h-9V3z"})],-1)])])}const da=be(Gh,[["render",Qh]]),eg=Object.freeze(Object.defineProperty({__proto__:null,default:da},Symbol.toStringTag,{value:"Module"})),tg={key:1,class:"h-5"},fa=ge({__name:"MangaPreferencesForm",props:{direction:{type:Number},readerStyle:{type:Number},gap:{type:Number},speed:{type:Number},zoom:{type:Number},webtoon:{type:Boolean},defaultPreferences:{type:Object},enableReset:{type:Boolean}},emits:["update:reader-style","update:direction","update:gap","update:speed","update:zoom"],setup(e,{emit:t}){const n=e,o=t,i=Q(()=>["Long strip",n.webtoon?void 0:"Single page",n.webtoon?void 0:"Double page"].filter(Boolean)),r=Q(()=>{const a=n.defaultPreferences;return!n.webtoon&&n.readerStyle!==a.readerStyle||!n.webtoon&&n.direction!==a.direction||n.gap!==a.gap||n.speed!==a.speed});function s(a){o("update:zoom",Math.round(a)/100)}function l(){o("update:reader-style",void 0),o("update:direction",void 0),o("update:gap",void 0),o("update:speed",void 0)}return(a,u)=>(v(),z(ye,null,[V(Le,{label:"Style"},{default:oe(()=>[V(mt,{"model-value":e.readerStyle,items:i.value,"onUpdate:modelValue":u[0]||(u[0]=c=>o("update:reader-style",c))},null,8,["model-value","items"])]),_:1}),V(Le,{label:"Direction"},{default:oe(()=>[V(mt,{"model-value":e.direction,items:e.webtoon?["Vertical"]:["Vertical","Left to right","Right to left"],"onUpdate:modelValue":u[1]||(u[1]=c=>o("update:direction",c))},null,8,["model-value","items"])]),_:1}),V(Le,{label:"Gap size"},{default:oe(()=>[V(mt,{"model-value":e.gap,items:["None","1px","2px","3px","4px","5px"],"onUpdate:modelValue":u[2]||(u[2]=c=>o("update:gap",c))},null,8,["model-value"])]),_:1}),V(Le,{label:"Play speed"},{default:oe(()=>[V(tn,{"model-value":e.speed,min:X(Qo),max:X(ei),step:X(ur),format:c=>`${c.toFixed(2)}x`,"onUpdate:modelValue":u[3]||(u[3]=c=>o("update:speed",c))},null,8,["model-value","min","max","step","format"])]),_:1}),V(Le,{label:"Zoom"},{default:oe(()=>[V(tn,{"model-value":Math.ceil(e.zoom*100),min:X(ti)*100,max:X(ni)*100,step:X(bh)*100,format:c=>`${Math.ceil(c)}%`,"onUpdate:modelValue":s},null,8,["model-value","min","max","step","format"])]),_:1}),e.enableReset?(v(),z("div",{key:0,class:ue(["w-full flex justify-center pt-1 duration-200",{"pointer-events-none opacity-0":!r.value,"opacity-90":r.value}])},[V(cr,{class:"w-2/3",onClick:l},{default:oe(()=>[...u[4]||(u[4]=[Wt(" Reset to default ",-1)])]),_:1})],2)):(v(),z("div",tg))],64))}}),ng=Object.freeze(Object.defineProperty({__proto__:null,default:fa},Symbol.toStringTag,{value:"Module"})),pa=ge({__name:"PageNav",props:Ye({disabled:{type:Boolean},pages:{type:Array},totalImgs:{type:Number}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=st(e,"modelValue"),o=Q(()=>t.pages.map(a=>a.map(({index:u})=>`${u+1}`).join("-"))),i=Q(()=>{const a=n.value,u=t.pages.findIndex(c=>c.some(({index:d})=>d===a));return u===-1?t.pages.length-1:u}),r=Q(()=>t.pages.length?`${o.value[i.value]}/${t.totalImgs}`:"--");function s(a){const u=t.pages[a][0].index;l(u)}function l(a){n.value=a}return(a,u)=>(v(),ie(sr,{"model-value":i.value,label:r.value,title:"Current page",items:o.value,disabled:e.disabled,"onUpdate:modelValue":s},null,8,["model-value","label","items","disabled"]))}}),og=Object.freeze(Object.defineProperty({__proto__:null,default:pa},Symbol.toStringTag,{value:"Module"})),gr=be(ge({__name:"PauseToast",props:{playing:{type:Boolean}},setup(e){const t=e,n=te(0);return de(()=>t.playing,()=>{n.value=Date.now()}),(o,i)=>n.value?(v(),z("div",{key:n.value,class:"animate-pause-fade fixed left-1/2 top-1/2 -mx-12 -my-12 pointer-events-none w-24 h-24 p-4 bg-black bg-opacity-40 rounded-full duration-500"},[e.playing?(v(),ie(nr,{key:0})):(v(),ie(tr,{key:1}))])):le("",!0)}}),[["styles",[".animate-pause-fade{animation:pause-fade .4s linear forwards;transform-origin:center}@keyframes pause-fade{0%{opacity:0;transform:scale(.3)}10%{opacity:1;transform:scale(.35)}55%{opacity:1;transform:scale(.65)}to{opacity:0;transform:scale(1)}}"]]]),ig=Object.freeze(Object.defineProperty({__proto__:null,default:gr},Symbol.toStringTag,{value:"Module"})),rg=30,mr=be(ge({__name:"ProgressBar",props:{value:{type:Number},total:{type:Number},longStrip:{type:Boolean},height:{type:Number},rtl:{type:Boolean},opacity:{type:Number}},setup(e){const t=e,n=Q(()=>Math.floor(t.value)+1),o=Q(()=>`${Math.max(2,Math.min(10,t.height))}px`),i=mn().width,r=Q(()=>t.total!==void 0&&i.value/t.total>=rg);return(s,l)=>(v(),z("div",{class:ue(["rprog",{"rprog--rtl":e.rtl}]),style:Ce({height:o.value,opacity:e.opacity??.8})},[r.value?(v(!0),z(ye,{key:0},Xt(e.total,a=>(v(),z("span",{key:a,class:ue(["rprog__item",{"rprog__item--active":n.value===a}]),style:Ce(!e.longStrip||n.value!==a?{}:{"--portion":`${e.value%1*100}%`})},null,6))),128)):(v(),z("div",{key:1,style:Ce({width:`${e.value/(e.total??1)*100}%`}),class:"h-full bg-textPrimary"},null,4))],6))}}),[["styles",['.rprog{--portion:100%;display:flex;width:100%}.rprog--rtl,.rprog--rtl .rprog__item{flex-direction:row-reverse}.rprog__item{display:inline-flex;flex-grow:1;flex-shrink:0;height:100%}.rprog__item:first-child:before{display:none}.rprog__item--active:before,.rprog__item:has(~.rprog__item--active):before{background-color:rgb(0 0 0/var(--tw-bg-opacity,1));content:"";display:block;flex-shrink:0;height:100%;width:1px;--tw-bg-opacity:.25}.rprog__item--active:after,.rprog__item:has(~.rprog__item--active):after{content:"";display:block;height:100%;--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1));width:var(--portion)}']]]),sg=Object.freeze(Object.defineProperty({__proto__:null,default:mr},Symbol.toStringTag,{value:"Module"})),ha=ge({__name:"GesturesContainer",props:{spaceTop:{type:Number},controlsVisible:{type:Boolean},zoom:{type:Number},zooming:{type:Boolean},pinchToZoome:{type:Boolean},tapZone:{type:Number},pageIndex:{type:Number},playController:{type:Object},rtl:{type:Boolean},horizontal:{type:Boolean},longStrip:{type:Boolean},touchDevice:{type:Boolean},busy:{type:Boolean}},emits:["update:zoom","update:zooming","dragEnd","click","prev","next"],setup(e,{expose:t,emit:n}){const o=e,i=n,r=te(null),s=te(Math.min(ni,Math.max(ti,o.zoom))),l=te(!1),a=te(!1),u={isZoomIn:!1,isZoomOut:!1,initial:void 0};t({rootEl:r}),de(()=>o.zoom,S=>W(S)),je(()=>{o.touchDevice?_t(r,"touchstart",k):(_t(r,"mousedown",h),_t(window,"wheel",L))}),$t({onKeyDown:S=>{var x;if(!o.busy&&((x=r.value)==null||x.focus(),!(S.key==="Meta"||S.key==="Control")&&(S.ctrlKey||S.metaKey)))switch(S.key){case"0":W(1);break;case"-":W(s.value-.2),S.preventDefault();break;case"=":case"+":W(s.value+.2),S.preventDefault();break}},onKeyUp:S=>{o.zooming&&!(S.ctrlKey||S.metaKey)&&G()}});function c(S){a.value!==S&&(a.value=S,S?o.playController.pause():(i("dragEnd"),o.playController.resume()))}let d={x:0,y:0},f={x:0,y:0};function h(S){if(S.button!==0)return;const x=r.value;x&&(d={x:S.clientX,y:S.clientY},f={x:x.scrollLeft,y:x.scrollTop},window.addEventListener("mousemove",w),window.addEventListener("mouseup",()=>{window.removeEventListener("mousemove",w),setTimeout(()=>c(!1))},{once:!0}),S.preventDefault(),S.stopPropagation())}function w(S){const x=S.clientX-d.x,U=S.clientY-d.y;if(!a.value&&Math.abs(x)<.5&&Math.abs(U)<.5)return;c(!0);const K=r.value;K&&(K.scrollLeft=f.x-x,K.scrollTop=f.y-U)}let y={distance:0,zoom:s.value,x:0,y:0},$=!1;function k(S){o.busy||($=o.pinchToZoome&&S.touches.length===2,$&&(i("update:zooming",!0),c(!0),S.stopPropagation(),S.preventDefault(),y={distance:Z(S),zoom:s.value,x:(S.touches[0].clientX+S.touches[1].clientX)/2,y:(S.touches[0].clientY+S.touches[1].clientY)/2}),($||o.longStrip&&o.playController.isPlaying.value)&&window.addEventListener("touchend",B,{once:!0}))}function B(){var K;if($=!1,o.zooming){c(!1),G();return}if(!a.value)return;const S=gt(()=>{var D;c(!1),(D=r.value)==null||D.removeEventListener("scroll",U)},200),x=setTimeout(S,200);(K=r.value)==null||K.addEventListener("scroll",U);function U(){clearTimeout(x),S()}}function A(S){if(!$&&!(o.longStrip&&o.playController.isPlaying.value)||(c(!0),!o.zooming)||(S.stopPropagation(),S.preventDefault(),S.touches.length<2))return;const U=Z(S)/y.distance;ee(Math.ceil(U*y.zoom*100)/100,y)}const b=gt(()=>l.value=!1,100);let g=!1;const E=gt(()=>{g=!1},30);function L(S){if(o.busy)return;let x=o.zooming;if(g||(g=!0,x=S.ctrlKey||S.metaKey,x&&i("update:zooming",!0)),E(),x){S.stopPropagation(),S.preventDefault();const U=Math.ceil((s.value+S.deltaY*-.01)*100)/100;ee(U,{x:S.clientX,y:S.clientY});return}o.horizontal&&(l.value||(l.value=!0),b(),S.deltaY&&(r.value&&(r.value.scrollLeft+=S.deltaY*(o.rtl?-1:1)),S.stopPropagation()))}function Z(S){return Math.hypot(S.touches[0].clientX-S.touches[1].clientX,S.touches[0].clientY-S.touches[1].clientY)}const _={x:0,y:0,ts:0};function O(S){if(a.value||o.zooming)return;const x=r.value;if(!x||j(x,S)||(i("click"),o.playController.isPlaying.value))return;const{clientX:U,clientY:K}=S,{x:D,y:fe,ts:ae}=_;_.x=U,_.y=K,_.ts=new Date().getTime();const he=_.ts-ae;he>250||he<10||Math.abs(D-U)>40||Math.abs(fe-K)>40||(_.ts=0,_.x=0,_.y=0,M(U,K))}function j(S,x){if(o.playController.isPlaying.value)return!1;const U=o.tapZone;if(U===pr.none)return!1;const K=o.controlsVisible?o.spaceTop:0,D=S.clientHeight-K,fe=Math.max(0,x.clientY-K),ae=o.horizontal?S.clientWidth:D;let he=!1,ve=!1;if(U){const{prevZones:we,nextZones:Ae}=sa[o.tapZone],at=Math.floor(fe/D*3);let Je=Math.floor(x.clientX/S.clientWidth*3);o.rtl&&(Je=2-Je);const De=at*3+Je;he=we.includes(De),ve=!he&&Ae.includes(De)}else{const Ae=(o.horizontal?o.rtl?ae-x.clientX:x.clientX:fe)/ae,at=o.horizontal?.2:.15;he=Ae<=at&&o.pageIndex>0,ve=!he&&Ae>=1-at}if(!he&&!ve)return!1;if(o.longStrip){const we=(he?-1:1)*.75*ae;o.horizontal?S.scrollLeft=S.scrollLeft+(o.rtl?-1:1)*we:S.scrollTop=Math.max(0,S.scrollTop+we)}else he?i("prev"):ve&&i("next");return!0}async function M(S,x){const U=s.value===1?2:1;await W(U,{x:S,y:x}),G()}function G(){i("update:zooming",!1),u.initial=void 0,u.isZoomIn=!1,u.isZoomOut=!1}function C(){if(u.initial)return;const S=r.value;if(!S)return;const x=S.querySelector(`[data-index="${o.pageIndex}"],[data-index2="${o.pageIndex}"]`)??void 0;x&&(u.initial={el:x,rect:x.getBoundingClientRect()})}function ee(S,x){if(u.isZoomIn=u.isZoomIn||!u.isZoomOut&&S>1,u.isZoomIn&&S<1){W(1,x);return}if(u.isZoomOut=u.isZoomOut||!u.isZoomIn&&S<1,u.isZoomOut&&S>1){W(1,x);return}W(S,x)}async function W(S,x){const U=r.value,K=Math.min(ni,Math.max(ti,S));if(!U||s.value===K)return;C();const{initial:D}=u;if(!D)return;const fe=(x==null?void 0:x.x)??U.clientWidth/2,ae=(x==null?void 0:x.y)??U.clientHeight/2;s.value=K,i("update:zoom",K),await pt();const{el:he,rect:ve}=D,we=he.offsetWidth/ve.width,Ae=he.offsetHeight/ve.height;U.scrollLeft=he.offsetLeft-ve.left*we+fe*(we-1),U.scrollTop=he.offsetTop-ve.top*Ae+ae*(Ae-1)}return(S,x)=>(v(),z("div",{ref_key:"rootEl",ref:r,tabindex:"0",class:ue(["w-full h-full overflow-auto scrollbar-none overscroll-contain scrollbar-none focus:outline-none touch-pan-x touch-pan-y",{"!snap-none":!e.longStrip&&(a.value||l.value||e.zooming),"cursor-grabbing":!e.touchDevice&&a.value,"overflow-hidden":e.zooming}]),style:Ce({"font-size":`${s.value}px`}),onClick:Be(O,["stop"]),onTouchmoveCapture:Be(A,["stop"])},[Se(S.$slots,"default")],38))}}),lg=Object.freeze(Object.defineProperty({__proto__:null,default:ha},Symbol.toStringTag,{value:"Module"})),ag=["src"],vr=ge({inheritAttrs:!1,__name:"ReaderImg",props:{src:{type:null},style:{type:Object}},setup(e){const t=e;let n;const o={mounted:i=>{if(t.src instanceof HTMLElement){const r=t.src.getBoundingClientRect();n=document.createElement("div"),n.style.setProperty("width",`${r.width}px`),n.style.setProperty("height",`${r.height}px`),t.src.replaceWith(n),i.appendChild(t.src)}},beforeUnmount:i=>{const r=i.children[0];n&&r&&(n.replaceWith(r),n=void 0)}};return(i,r)=>typeof e.src=="string"?(v(),z("img",{key:0,src:e.src,class:ue(i.$attrs.class??""),style:Ce(e.style)},null,14,ag)):Re((v(),z("div",{key:1,class:ue(i.$attrs.class??""),style:Ce(e.style)},null,6)),[[o]])}}),cg=Object.freeze(Object.defineProperty({__proto__:null,default:vr},Symbol.toStringTag,{value:"Module"}));function br(e,t){return(e==null?void 0:e.querySelector(`[data-index="${t}"],[data-index2="${t}"]`))??void 0}const ug=["data-index"],dg={key:0,class:"rbod__page rbod__page--loading"},fg=["data-index"],ga=be(ge({__name:"ReaderBody",props:{page:{type:Number},pageIndex:{type:Number},direction:{type:Number},isLongStrip:{type:Boolean},isVertical:{type:Boolean},isDouble:{type:Boolean},isRTL:{type:Boolean},pages:{type:Array},totalImgs:{type:Number},gap:{type:Number},zoom:{type:Number},zooming:{type:Boolean},pinchToZoome:{type:Boolean},tapZone:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},playController:{type:Object},busy:{type:Boolean},controlsVisible:{type:Boolean}},emits:["ready","update:zoom","update:zooming","update:playing","dragEnd","click","end","prev","next"],setup(e,{expose:t,emit:n}){const o=e,i=n,r=te(null),s=Q(()=>{var A;return(A=r.value)==null?void 0:A.rootEl});t({rootEl:s});const l=mn(),a=Q(()=>{const{width:A,height:b}=l,g=o.isLongStrip?o.isVertical?A.value:b.value:Math.min(A.value,b.value);return Math.min(4,Math.max(1,Math.ceil(g/400-1)))*o.gap}),u=te(o.isLongStrip?{min:o.pageIndex-1,max:o.pageIndex}:$()),c=Q(()=>{const{min:A,max:b}=u.value,g={};for(let E=A;E<=b;E++)g[E]=!0;return g}),d=te(h()),f=Mn(()=>{d.value=h(),pt(()=>y())},100);de(l.width,f),de(l.height,f),de(()=>o.pages,f),de(()=>o.isLongStrip,f),de(()=>o.isVertical,f);function h(){const A=l.width.value,b=l.height.value,{pages:g,isLongStrip:E,isVertical:L}=o;return g.map(Z=>{var S;const _=Z.some(x=>{var U;return(U=x.img)==null?void 0:U.isLoading}),O=Z.map(x=>x.index),j={isLoading:_,indexes:O,visible:!1};if(_)return j;const M=Z.map(({img:x})=>x).filter(Boolean);if(!M.length||(j.srcs=M.map(({src:x})=>x),M.every(x=>x.hasError)))return j;const C=(S=M.find(x=>!x.hasError))==null?void 0:S.size;if(!C)return j;const ee=M.reduce((x,U)=>{var K;return x+(((K=U.size)==null?void 0:K.width)??C.width)},0),W=M.reduce((x,U)=>{var K;return x+(((K=U.size)==null?void 0:K.height)??C.height)},0)/M.length;return E&&L||!E&&A/ee<b/W?(j.width=Math.min(A,ee),j.height=W*(j.width/ee)):(j.height=Math.min(b,W),j.width=ee*(j.height/W)),j.width&&j.height&&(j.style={width:`${j.width}em`,height:`${j.height}em`}),j})}const w=Q(()=>{const A=o.isVertical?"width":"height";return d.value.map(b=>b[A]).filter(Boolean).sort((b,g)=>g-b)[0]});je(()=>{const A=br(s.value,o.pageIndex);A==null||A.scrollIntoView({behavior:"instant",block:"start"});let b,g=!1;Fs(()=>{b!==o.pageIndex&&(b=o.pageIndex,y(),g||(g=!0,pt(()=>i("ready"))))})});async function y(){if(!o.isLongStrip){u.value=$();return}const A=Math.floor(o.page),b=br(s.value,A);if(!b)return;const g=+k(b).getAttribute("data-index"),E=+B(b).getAttribute("data-index");(g!==u.value.min||E!==u.value.max)&&(u.value={min:g,max:E})}function $(){const{pageIndex:A}=o;return{min:A-(o.isDouble?5:3),max:A+(o.isDouble?6:3)}}function k(A,b=0){const g=A.previousElementSibling;if(!g)return A;const E=b+(o.isVertical?g.clientHeight:g.clientWidth);return(o.isVertical?E>l.height.value*1.5:o.isRTL?E>l.width.value*2.5:E>l.width.value*1.5)?g:k(g,E)}function B(A,b=0){const g=A.nextElementSibling;if(!g)return A;const E=b+(o.isVertical?g.clientHeight:g.clientWidth);return(o.isVertical?E>l.height.value*3.5:o.isRTL?E>l.width.value*1.5:E>l.width.value*2.5)?g:B(g,E)}return(A,b)=>(v(),ie(ha,{ref_key:"gestureContainer",ref:r,"space-top":e.spaceTop,"controls-visible":e.controlsVisible,zoom:e.zoom,zooming:e.zooming,"pinch-to-zoome":e.pinchToZoome,"tap-zone":e.tapZone,"page-index":e.pageIndex,class:ue(["rbod",{"rbod--long-strip":e.isLongStrip,"rbod--paging":!e.isLongStrip,"rbod--vertical":e.isVertical,"rbod--rtl":e.isRTL,"rbod--1page":d.value.length===1}]),"play-controller":e.playController,horizontal:!e.isVertical,rtl:e.isRTL,"touch-device":e.touchDevice,busy:e.busy,"long-strip":e.isLongStrip,style:Ce({"--gap":`${a.value}em`,"--space-top":`${e.spaceTop}px`,"--screen-width-em":X(l).width.value+"em","--screen-height-em":X(l).height.value+"em",...e.isLongStrip?{"--max-size-em":w.value+"em"}:{}}),"onUpdate:zoom":b[0]||(b[0]=g=>i("update:zoom",g)),"onUpdate:zooming":b[1]||(b[1]=g=>i("update:zooming",g)),onDragEnd:b[2]||(b[2]=()=>i("dragEnd")),onClick:b[3]||(b[3]=()=>i("click")),onPrev:b[4]||(b[4]=()=>i("prev")),onNext:b[5]||(b[5]=()=>i("next"))},{default:oe(()=>[(v(!0),z(ye,null,Xt(d.value,g=>{var E;return v(),z("div",kn({key:e.direction+"_"+g.indexes[0],"data-index":g.indexes[0]},{ref_for:!0},g.indexes.length>1?{"data-index2":g.indexes[1]}:{}),[!((E=g.srcs)!=null&&E.length)||g.isLoading?(v(),z("div",dg,[c.value[g.indexes[0]]?(v(),ie(oi,{key:0})):le("",!0)])):g.srcs.length==1?(v(),z(ye,{key:1},[c.value[g.indexes[0]]?(v(),ie(vr,{key:1,class:"rbod__page img",src:g.srcs[0],style:Ce(g.style)},null,8,["src","style"])):(v(),z("div",{key:0,class:"rbod__page",style:Ce(g.style)},null,4))],64)):(v(),z("div",{key:2,class:ue(["rbod__page rbod__page--double",{"flex-row-reverse":e.isRTL}]),style:Ce(g.style)},[g.indexes.some(L=>c.value[L])?(v(!0),z(ye,{key:0},Xt(g.srcs,(L,Z)=>(v(),z("div",{key:typeof L=="string"?L:`${Z}-${g.height}`},[V(vr,{src:L,class:"img"},null,8,["src"])]))),128)):le("",!0)],6))],16,ug)}),128)),Y("div",{class:"last","data-index":e.totalImgs},[Se(A.$slots,"end")],8,fg)]),_:3},8,["space-top","controls-visible","zoom","zooming","pinch-to-zoome","tap-zone","page-index","play-controller","horizontal","rtl","touch-device","busy","long-strip","class","style"]))}}),[["styles",[".rbod{--tw-translate-y:0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@media (min-width:1024px){.rbod{transform:none}}.rbod--rtl{flex-direction:row-reverse}.rbod.rbod--vertical>div{padding:calc(var(--gap)/2) 0}.rbod:not(.rbod--vertical){align-items:center;display:flex;height:100%;justify-content:flex-start}.rbod:not(.rbod--vertical)>div{padding:0 calc(var(--gap)/2)}.rbod--long-strip.rbod--vertical.rbod--1page>div:first-child{min-height:100vh}.rbod--long-strip.rbod--vertical>div:first-child{margin-top:var(--space-top);padding-top:0}.rbod--long-strip.rbod--vertical>div:last-child{padding-bottom:0}.rbod--long-strip.rbod--vertical>div{width:var(--max-size-em)}.rbod--long-strip.rbod--vertical .rbod__page--loading{height:75vh;width:100%}.rbod--long-strip.rbod--vertical .last{height:100vh}.rbod--long-strip:not(.rbod--vertical).rbod--1page>div:first-child{min-width:100vw}.rbod--long-strip:not(.rbod--vertical)>div{align-items:center;display:flex;height:var(--max-size-em)}.rbod--long-strip:not(.rbod--vertical) .rbod__page--loading{height:100%;max-width:100vw;width:680px}.rbod--long-strip:not(.rbod--vertical) .last{width:100vw}.rbod--long-strip>div>.img{flex-shrink:0;margin:auto}.rbod--paging>div{align-items:center;display:grid;justify-content:center;min-height:100vh;min-width:100vw;scroll-snap-align:center;scroll-snap-stop:always}.rbod--paging.rbod--vertical{scroll-snap-type:y var(--tw-scroll-snap-strictness);--tw-scroll-snap-strictness:mandatory}.rbod--paging.rbod--vertical>div{width:var(--screen-width-em)}.rbod--paging:not(.rbod--vertical){scroll-snap-type:x var(--tw-scroll-snap-strictness);--tw-scroll-snap-strictness:mandatory}.rbod--paging:not(.rbod--vertical)>div{height:var(--screen-height-em)}.rbod--paging .rbod__page--loading{height:100%;width:100%}.rbod--paging .rbod__page.rbod__page--double{align-items:center;background-color:transparent;display:flex;gap:var(--gap);justify-content:center}.rbod--paging .rbod__page.rbod__page--double div{display:flex;height:100%;-webkit-user-select:none;-moz-user-select:none;user-select:none;--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.rbod--paging .rbod__page.rbod__page--double div .img{flex-shrink:0;max-height:100%;max-width:100%;-o-object-fit:contain;object-fit:contain}.rbod>div{flex-shrink:0}.rbod .rbod__page,.rbod>div{margin:auto;-webkit-user-select:none;-moz-user-select:none;user-select:none}.rbod .rbod__page{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1));-o-object-fit:contain;object-fit:contain}.rbod .rbod__page--loading{align-items:center;background-color:transparent;display:flex;justify-content:center}.rbod .img canvas,.rbod .img img{height:100%;max-height:100%;max-width:100%;width:100%}"]]]),pg=Object.freeze(Object.defineProperty({__proto__:null,default:ga},Symbol.toStringTag,{value:"Module"})),hg={},gg={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function mg(e,t){return v(),z("svg",gg,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M19 6.41L17.59 5L12 10.59L6.41 5L5 6.41L10.59 12L5 17.59L6.41 19L12 13.41L17.59 19L19 17.59L13.41 12z"},null,-1)])])}const ma=be(hg,[["render",mg]]),vg=Object.freeze(Object.defineProperty({__proto__:null,default:ma},Symbol.toStringTag,{value:"Module"})),bg={class:"flex w-full flex-shrink-0 justify-between items-center h-16 px-3"},va=ge({__name:"BottomSheet",props:Ye({spaceTop:{type:Number}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=st(e,"modelValue"),n=te(null),o=te(!1),i=te(0);$t({onKeyDown:s});const r=Yo();de(t,c=>r(c)),Xi(()=>{const c=t.value;return c&&(t.value=!1),c});function s(c){t.value&&c.key==="Escape"&&(t.value=!1,c.preventDefault())}const l={y:-1};function a(c){const d=n.value;if(!d)return;if(d.scrollTop>0){l.y=-1;return}if(l.y===-1){l.y=Math.max(0,c.touches[0].clientY);return}const h=c.touches[0].clientY-l.y,w=h>0?h:0;w!=i.value&&(i.value=w);const y=w>0;y!==o.value&&(o.value=y)}async function u(){o.value=!1,l.y=-1,await pt();const c=n.value;c&&c.offsetHeight-i.value<window.innerHeight/2&&i.value>c.offsetHeight*.3&&(t.value=!1),i.value=0}return(c,d)=>(v(),z("div",{class:ue(["fixed inset-0 flex flex-col items-center justify-end select-none z-40 text-stone-100",{"!pointer-events-none":!t.value}]),style:Ce({"padding-top":(e.spaceTop??0)+60+"px"}),onClick:d[3]||(d[3]=()=>t.value=!1)},[V(Gn,{"enter-from-class":"!translate-y-full","leave-to-class":"!translate-y-full"},{default:oe(()=>[t.value?(v(),z("div",{key:0,class:ue(["w-full sm:w-[31rem] bg-stone-900 bg-opacity-90 backdrop-blur-md rounded-t-xl max-w-full overflow-hidden shadow-lg shadow-neutral-950",{"duration-0":o.value,"duration-200":!o.value}]),style:Ce(i.value?{transform:`translateY(${i.value}px)`}:{}),onClick:d[1]||(d[1]=Be(()=>{},["stop"])),onWheelPassive:d[2]||(d[2]=Be(()=>{},["stop"])),onTouchmove:Be(a,["stop"]),onTouchend:u},[Y("div",bg,[V(Ge,{transparent:"",onClick:d[0]||(d[0]=()=>t.value=!1)},{default:oe(()=>[V(ma)]),_:1}),Se(c.$slots,"name"),Se(c.$slots,"actions")]),Y("div",{ref_key:"scrollEl",ref:n,class:ue(["overflow-auto overscroll-none px-6 md:px-8 lg:px-10 xl:px-12 pt-1.5 pb-8 md:pb-6 flex-grow scrollbar-sm",{"overflow-hidden":o.value}]),style:{"max-height":"calc(100% - 4rem)"}},[Se(c.$slots,"default")],2)],38)):le("",!0)]),_:3})],6))}}),yg=Object.freeze(Object.defineProperty({__proto__:null,default:va},Symbol.toStringTag,{value:"Module"})),wg=["onClick","onKeyup"],ba=be(ge({__name:"TabBar",props:Ye({items:{type:Array}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=st(e,"modelValue"),o=te(null),i=te({width:"",left:""}),r=te(!1);je(()=>{const l=Date.now();de(n,async a=>{var c;await pt();const u=(c=o.value)==null?void 0:c.children[a+1];u&&(i.value={width:u.offsetWidth+"px",left:u.offsetLeft+"px"},!r.value&&Date.now()-l>500&&(r.value=!0),u.scrollIntoView({behavior:r.value?"smooth":"auto",block:"center",inline:"center"}))},{immediate:!0})});function s(l){n.value=l}return(l,a)=>(v(),z("div",{ref_key:"root",ref:o,class:"relative h-8 rounded-[2.5rem] inline-flex bg-black bg-opacity-50 p-1 font-medium max-w-full leading-none overflow-auto scrollbar-none",style:{}},[Y("div",{class:ue(["bg-stone-300 h-6 rounded-2xl absolute top-1 pointer-events-none",{"duration-200":r.value}]),style:Ce(i.value)},null,6),(v(!0),z(ye,null,Xt(t.items,(u,c)=>Re((v(),z("div",{key:c,tabindex:"0",class:ue(["text-sm inline-flex justify-center items-center h-6 rounded-2xl px-4 cursor-pointer relative z-10 whitespace-nowrap flex-shrink-0 focus:outline-primary hover:bg-stone-50 hover:bg-opacity-10 duration-200",{"text-stone-900":c==n.value,"text-stone-400":c!=n.value}]),onClick:Be(()=>s(c),["stop"]),onKeyup:[qo(()=>s(c),["enter"]),qo(()=>s(c),["space"])]},[Wt(Fe(u),1)],42,wg)),[[X(zt),30]])),128))],512))}}),[["styles",[".scrollbar-none{scrollbar-width:none}.scrollbar-none::-webkit-scrollbar{display:none}"]]]),xg=Object.freeze(Object.defineProperty({__proto__:null,default:ba},Symbol.toStringTag,{value:"Module"})),_g={},Sg={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function kg(e,t){return v(),z("svg",Sg,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10s10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8s8 3.59 8 8s-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5c0-2.21-1.79-4-4-4z"},null,-1)])])}const ya=be(_g,[["render",kg]]),Cg=Object.freeze(Object.defineProperty({__proto__:null,default:ya},Symbol.toStringTag,{value:"Module"})),Tg={},Mg={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 28 28"};function Pg(e,t){return v(),z("svg",Mg,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M14 8.25a2.25 2.25 0 1 1 0-4.5a2.25 2.25 0 0 1 0 4.5m0 8a2.25 2.25 0 1 1 0-4.5a2.25 2.25 0 0 1 0 4.5M11.75 22a2.25 2.25 0 1 0 4.5 0a2.25 2.25 0 0 0-4.5 0"},null,-1)])])}const wa=be(Tg,[["render",Pg]]),Eg=Object.freeze(Object.defineProperty({__proto__:null,default:wa},Symbol.toStringTag,{value:"Module"})),Ig={key:1,class:"w-full text-center text-xl whitespace-nowrap text-ellipsis flex-shrink overflow-hidden px-5 select-text"},Og={class:"opacity-90"},$g={key:0,class:"w-full text-center text-sm text-stone-400 whitespace-nowrap text-ellipsis flex-shrink overflow-hidden mb-3 -mt-2 select-text px-4"},yr=ge({__name:"SettingsBottomSheet",props:Ye({name:{type:String},spaceTop:{type:Number},enableHelp:{type:Boolean},enableDefaultPreferences:{type:Boolean}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:Ye(["help","more"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=st(e,"modelValue"),r=te(0),s=Q(()=>n.name??location.hostname);$t({onKeyUp:a=>{a.key==="s"&&!a.metaKey&&!a.ctrlKey&&(i.value=!0)}}),je(()=>{de(i,a=>{a||setTimeout(()=>{r.value!==0&&(r.value=0)},300)})});function l(){o("help"),i.value=!1}return(a,u)=>(v(),ie(va,{modelValue:i.value,"onUpdate:modelValue":u[2]||(u[2]=c=>i.value=c),"space-top":e.spaceTop},{name:oe(()=>[e.enableDefaultPreferences?(v(),ie(ba,{key:0,modelValue:r.value,"onUpdate:modelValue":u[0]||(u[0]=c=>r.value=c),items:["Preferences","Default"]},null,8,["modelValue"])):(v(),z("h3",Ig,Fe(s.value),1))]),actions:oe(()=>[e.enableDefaultPreferences?(v(),ie(Ge,{key:0,transparent:"",class:ue(e.enableHelp?"":"opacity-0 pointer-events-none"),onClick:l},{default:oe(()=>[Y("span",Og,[V(ya)])]),_:1},8,["class"])):(v(),ie(Ge,{key:1,transparent:"",onClick:u[1]||(u[1]=()=>o("more"))},{default:oe(()=>[V(wa)]),_:1}))]),default:oe(()=>[r.value===0?(v(),z(ye,{key:0},[e.enableDefaultPreferences?(v(),z("h3",$g,Fe(s.value),1)):le("",!0),Se(a.$slots,"tab-preferences")],64)):(v(),z(ye,{key:1},[Se(a.$slots,"tab-default"),u[3]||(u[3]=Y("div",{class:"h-6"},null,-1))],64))]),_:3},8,["modelValue","space-top"]))}}),zg=Object.freeze(Object.defineProperty({__proto__:null,default:yr},Symbol.toStringTag,{value:"Module"}));function oo(e=0){return new Promise(t=>setTimeout(t,e))}const wr={};async function xa(e){Dg();const t=(()=>{const r=e.width,s=e.height;if(r&&s)return{width:r,height:s};const l=e.getBoundingClientRect();return{width:l.width,height:l.height}})(),n=await _a(e);if(n)return{size:t,src:n};const o=Ag(e);if(!o)return;const i=await _a(o);return i?{size:t,src:i}:{size:t,src:Lg(o,t)}}function Dg(){var o,i;if(wr.toBlob)return;const e=document.createElement("template");e.innerHTML="<iframe></iframe>";const t=e.content.querySelector("iframe");t&&(t==null||t.style.setProperty("style","none"),document.body.appendChild(t));const n=(i=(o=t==null?void 0:t.contentWindow)==null?void 0:o.HTMLCanvasElement)==null?void 0:i.prototype;wr.toBlob=(n==null?void 0:n.toBlob)??HTMLCanvasElement.prototype.toBlob,t&&document.body.removeChild(t)}function Ag(e){var o;const t=e.cloneNode(),n=(o=t.getContext)==null?void 0:o.call(t,"2d");if(n){try{n.drawImage(e,0,0)}catch{return}return t}}function _a(e){return new Promise(t=>{const n=o=>{if(!o)return t(void 0);const i=URL.createObjectURL(o);t(i)};try{wr.toBlob.call(e,n,"image/jpeg",1)}catch{t(void 0)}})}function Lg(e,t){const n=Array.from(e.attributes);return n.forEach(o=>{o.name!=="width"&&o.name!=="height"&&e.removeAttribute(o.name)}),n.some(o=>o.name==="width")||e.setAttribute("width",`${t.width}`),n.some(o=>o.name==="height")||e.setAttribute("height",`${t.height}`),e}let ii;async function jg(e,t){if(ii||!t.startsWith("blob:"))return t;if(ii===void 0){try{if((await fetch(t)).ok)return ii=!0,t}catch{}ii=!1}e.complete||await new Promise(l=>{let a=0;const u=setInterval(()=>{e.complete?(l(),clearInterval(u)):++a>=30&&l()},100)});const o=e.naturalWidth,i=e.naturalHeight;if(!o||!i)return;const r=document.createElement("canvas"),s=r.getContext("2d");return r.width=o,r.height=i,s==null||s.drawImage(e,0,0,o,i),await xa(r)}function Bg(e){const t=new Set,n=e.getAttributeNames(),o=n.indexOf("src"),i=o!==-1;i&&(n.splice(o,1),n.push("src"));for(const r of n){if(r==="srcset"||i&&r===":src"||r!=="data-url"&&r!=="data-original"&&!r.includes("src"))continue;const s=e.getAttribute(r);s&&(r==="src"&&e.naturalWidth&&e.naturalWidth<200||t.add(s.replace(/(\n|\t)/g," ").trim()))}return Array.from(t)}class Ng{constructor({onChanged:t}){Pe(this,"isMounted",!0);Pe(this,"elsDisposeCallbacksMap",new Map);Pe(this,"onChanged");this.onChanged=t}dispose(){this.isMounted=!1,this.elsDisposeCallbacksMap.forEach(t=>t()),this.elsDisposeCallbacksMap=new Map,this.onChanged=()=>{}}async download(t){if(!this.isMounted)return;const n=t.el;if(n){if(!gn(n)){this.onChanged(t,{src:"",isLoading:!1,hasError:!1,invalid:!0});return}if(n instanceof HTMLCanvasElement)return await this.downloadCanvas(t,n);if(n instanceof HTMLImageElement)return await this.downloadImgEl(t,n)}t.src&&await this.downloadRawSrc(t,t.src)}async downloadCanvas(t,n){this.setupCanvasObserver(n,t);const o=await xa(n);!o||!this.isMounted||this.onChanged(t,{src:o.src,size:o.size,isLoading:!1,hasError:!1,invalid:!Qn(o.size.width,o.size.height)})}setupCanvasObserver(t,n){if(this.elsDisposeCallbacksMap.has(t))return;const o=t.getContext("2d");if(o){const i=o.drawImage.bind(o),r=o.putImageData.bind(o),s=Mn(()=>{this.isMounted&&this.download(n)},120),l=(a,u,c)=>(s(),Reflect.apply(a,u,c));try{o.drawImage=new Proxy(i,{apply:l}),o.putImageData=new Proxy(r,{apply:l})}catch{}this.elsDisposeCallbacksMap.set(t,()=>{try{o.drawImage=i,o.putImageData=r}catch{}})}}async downloadImgEl(t,n){this.setupImgElObserver(n,t);const o=Bg(n);if(o.length){this.onChanged(t,{src:o[0],isLoading:!0,hasError:!1});for(let i=0;i<o.length;i++){const r=o[i],s=await jg(n,r);if(!s)continue;if(s&&typeof s!="string"){this.onChanged(t,{src:s.src,size:s.size,isLoading:!1,hasError:!1});return}const l=await Sa(s,n,a=>{this.isMounted&&this.onChanged(t,{src:s,size:a,isLoading:!1,hasError:!1})});if(l.ok||!this.isMounted)return;i===o.length-1&&this.onChanged(t,{src:s,isLoading:!1,hasError:!!l.error,invalid:!!l.invalid,size:l.size})}}}setupImgElObserver(t,n){if(this.elsDisposeCallbacksMap.has(t))return;let o=t.getAttribute("src");const i=new MutationObserver(r=>{r.some(l=>{if(l.attributeName!=="src")return!1;const a=o;return o=t.getAttribute("src"),!!o&&a!==o})&&this.download(n)});i.observe(t,{attributes:!0}),this.elsDisposeCallbacksMap.set(t,()=>i.disconnect())}async downloadRawSrc(t,n){this.onChanged(t,{src:n,isLoading:!0,hasError:!1});const o=await Sa(n,void 0,i=>{this.isMounted&&this.onChanged(t,{src:n,size:i,isLoading:!1,hasError:!1})});o.ok||!this.isMounted||this.onChanged(t,{src:n,isLoading:!1,hasError:!!o.error,invalid:!!o.invalid,size:o.size})}}async function Sa(e,t,n){return(t==null?void 0:t.src)===e&&t.naturalWidth&&t.naturalHeight?(n({width:t.naturalWidth,height:t.naturalHeight}),t.complete?{ok:!0}:new Promise(o=>{t.addEventListener("load",()=>o({ok:!0}),{once:!0})})):await new Promise(o=>{const i=new Image,r=setInterval(()=>{const{naturalWidth:s,naturalHeight:l}=i;if(l&&s){const a={width:s,height:l};Qn(s,l)?n(a):o({invalid:!0,size:a}),clearInterval(r)}},20);i.onerror=()=>{o({error:!0}),clearInterval(r)},i.onload=()=>setTimeout(()=>o({ok:!0}),25),i.src=e})}const Vg=3;class Rg{constructor(t){Pe(this,"download");Pe(this,"threads");Pe(this,"completedItems");Pe(this,"promisesMap",new Map);this.download=t.download}dispose(){var t;(t=this.threads)==null||t.dispose(),this.threads=void 0,this.completedItems=void 0}run({activeIndex:t,items:n}){var r;if(this.completedItems===n)return;this.completedItems=void 0,(r=this.threads)==null||r.dispose();let o=Math.max(0,t-1),i=!0;this.threads=new Hg(Vg,()=>{const s=n[o];if(!s){this.completedItems=n;return}i&&o===n.length-1?(i=!1,o=t-2):i?o++:o--;const l=s.src??s.el;if(l){const u=this.promisesMap.get(l);if(u)return u}const a=this.download(s);return l&&this.promisesMap.set(l,a),a}),this.threads.exec()}}class Hg{constructor(t,n){Pe(this,"isDisposed",!1);this.limit=t,this.getNext=n}dispose(){this.isDisposed=!0}exec(){for(let t=0;t<this.limit;t++)this.next()}async next(){if(this.isDisposed)return;const t=this.getNext();t&&(await t,await oo(20),this.next())}}function Fg(e,t){let n=[t??document.documentElement];const o=e.split("->");for(let i=0;i<o.length;i++){const r=o[i];n=n.map(s=>Array.from((s.shadowRoot??s).querySelectorAll(r))).flat()}return n}function io(e,t){if(e instanceof HTMLOptionElement){const n=e.parentElement instanceof HTMLOptGroupElement?e.parentElement.parentElement:e.parentElement;if(!n||!(n instanceof HTMLSelectElement))return;const o=e.getAttribute("value")||"";if(n.value===o)return;n.value=o,n.dispatchEvent(new Event("change"));return}e instanceof HTMLAnchorElement&&(t==null?void 0:t.preventDefault)!==!1&&e.addEventListener("click",n=>n.preventDefault(),{once:!0}),e.click(),e.dispatchEvent(new PointerEvent("pointerdown",{bubbles:!0,cancelable:!0,pointerType:"mouse",button:0})),e.dispatchEvent(new MouseEvent("mousedown",{bubbles:!0,cancelable:!0,view:window,button:0}))}function ka(e,t){const n=document;if(e.startsWith("//")){const i=document.evaluate(e,document,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue;return i instanceof HTMLElement?i:void 0}return n.querySelector(e)??void 0}async function Wg(e){const{lstrip:t,lstripBtn:n}=e||{};if(!t||!n||!!ka(t))return!1;const i=n.split(";");for(const r of i)if(!await Ug(r.trim()))return!1;return!0}async function Ug(e){const t=await en(50,30,()=>ka(e));return t?(io(t),await oo(),!0):!1}class qg{constructor({spec:t,onChanged:n}){Pe(this,"spec");Pe(this,"onChanged");Pe(this,"rawImages",[]);Pe(this,"isMounted",!0);Pe(this,"loadRawImagesTs");Pe(this,"imgListenersMap",new Map);Pe(this,"disconnectObservers");Pe(this,"contentEl");Pe(this,"reloadRawImages",gt(()=>{this.contentEl&&this.loadRawImages(this.contentEl)},100));this.spec=t,this.onChanged=n,this.init()}dispose(){var t;this.isMounted=!1,(t=this.disconnectObservers)==null||t.call(this),this.disconnectObservers=void 0,this.onChanged=()=>{}}init(){var i;const t=new MutationObserver(this.reloadRawImages),n=(i=this.spec)!=null&&i.imgDivs?void 0:(()=>{let r=window.innerWidth;return new ResizeObserver(gt(()=>{const s=window.innerWidth;if(s!==r){r=s;return}this.reloadRawImages()},50))})();this.disconnectObservers=async()=>{t.disconnect(),n==null||n.disconnect()};let o=!1;this.loadContentEl(r=>{this.contentEl!==r&&(this.contentEl=r,t.disconnect(),n==null||n.disconnect(),t.observe(this.contentEl,{childList:!0,subtree:!0}),n==null||n.observe(this.contentEl),o?this.reloadRawImages():(o=!0,this.loadRawImages(this.contentEl)))})}setRawImages(t){let n=!1;const o=t.map((i,r)=>{const s=this.rawImages[r];return s&&s.parentEl===i.parentEl&&(s.el===i.el||s.parentEl&&s.el&&!i.el)&&s.src===i.src?s:(n=!0,i)});(n||o.length!==this.rawImages.length)&&(this.rawImages=o,this.onChanged(t))}async loadContentEl(t){var l;const n=await Wg(this.spec),o=(l=this.spec)==null?void 0:l.content;if(!o){t(document.body);return}let i=await en(n?100:1,10,()=>{for(const a of o.split(",")){const u=document.querySelector(a);if(u)return u}});if(!i)return;t(i);let r=0;const s=async()=>{if(this.isMounted&&!(i!=null&&i.isConnected)){if(r=0,i=await en(50,20,()=>{const a=document.querySelector(o);return a!=null&&a.isConnected&&a!==i?a:void 0}),!i)return;t(i)}!this.isMounted||++r>=10||setTimeout(s,200)};setTimeout(s,200)}async loadRawImages(t){var r;if(!this.isMounted||!t.isConnected)return;const n=Date.now();this.loadRawImagesTs=n;const o=(r=this.spec)==null?void 0:r.imgDivs,i=o?await this.loadFromImgDivs(t,o):this.loadFromContentEl(t);this.loadRawImagesTs!==n||!t.isConnected||!this.isMounted||this.setRawImages(i)}async loadFromImgDivs(t,n){const o=Fg(n,t);return o.length?o.map(r=>{const s=Array.from(r.querySelectorAll("img:not(nav img, header img, footer img, aside img),canvas"));for(const l of s){if(!gn(l,t)){this.observeInvalidImgEl(l);continue}if(l instanceof HTMLCanvasElement){if(Ca(l))return{el:l,parentEl:r}}else if(l instanceof HTMLImageElement){if(Ta(l))return{el:l,parentEl:r};this.observeInvalidImgEl(l)}}return{parentEl:r}}):this.loadFromContentEl(t)}loadFromContentEl(t){const n=[],o=Array.from(t.querySelectorAll("img:not(nav img, header img, footer img, aside img),canvas")),i=r=>{if(!gn(r,t))return!1;if(r instanceof HTMLCanvasElement){if(Ca(r))return n.push({el:r}),!0}else if(Ta(r))return n.push({el:r}),!0;return!1};return o.forEach(r=>{i(r)||this.observeInvalidImgEl(r)}),n}observeInvalidImgEl(t){if(!(t instanceof HTMLImageElement)||this.imgListenersMap.has(t))return;const n=()=>{t.removeEventListener("load",n),this.imgListenersMap.delete(t),this.reloadRawImages()};this.imgListenersMap.set(t,n),t.addEventListener("load",n)}}function Ca(e){return e.isConnected&&Qn(e.width,e.height)}function Ta(e){if(!e.isConnected)return!1;const t=e.getBoundingClientRect();return!t.width&&!e.naturalWidth||!t.height&&!e.naturalHeight||Qn(t.width,t.height)}const ri="mp-scroll-container";class xr{constructor(){Pe(this,"scrollEl")}dispose(){var t;(t=this.scrollEl)==null||t.classList.remove(ri)}scrollTo({rawImages:t,page:n,skipIfVisible:o,isScrollDown:i,isScrollExact:r,fallbackScrollEl:s}){var $;const l=Math.floor(n),a=t[Math.min(t.length-1,l)];if(!a)return;const u=a.el??a.parentEl??(a.src?document.querySelector(`img[src^="${a.src}"]`):void 0);if(!u)return;const c=u.getBoundingClientRect();if(o&&c.top<=0&&c.top+c.height>0)return;const d=xr.getScrollable(u,s);if(!d)return;const{el:f,top:h}=d;s!==document.documentElement&&!f.classList.contains(ri)&&(f!==this.scrollEl&&(($=this.scrollEl)==null||$.classList.remove(ri),this.scrollEl=f),f.classList.add(ri));const w=n>=t.length?c.height:r?n%1*c.height:i?Math.max(0,c.height-window.innerHeight/2):-window.innerHeight/2,y={top:h+w,behavior:"instant"};f.scrollTo(y),f!==document.documentElement&&document.documentElement.scrollTo(y)}static getScrollable(t,n){const o=(i,r)=>{if(!i)return;const{offsetTop:s,offsetParent:l}=i;if(l&&s&&r.set(l,Math.max(r.get(l)??0,s)),!(i===n||i.scrollHeight-i.clientHeight>=10&&window.getComputedStyle(i).overflow!=="visible"))return o(i.parentElement,r);let u=0;return r.forEach((c,d)=>{u+=d===l?c-s:c}),{el:i,top:u}};return o(t,new Map)}}function Ma(e){var t,n;for(let o=0;o<e.length;o++){const i=((t=e[o])==null?void 0:t.el)??((n=e[o])==null?void 0:n.parentEl),r=i==null?void 0:i.getBoundingClientRect();if(!r||r.bottom<=0)continue;const s=r.top;return o+(s>=0?0:-s/r.height)}return 0}function Kg(e){if(document.documentElement.scrollTop<700)return 0;const n=Array.from(document.querySelectorAll("img[src]")).filter(o=>e.includes(o.src)).map(o=>({el:o}));return Ma(n)}function Zg(e){var _,O,j;const t=(_=e.raw.value)==null?void 0:_.isWebtoon,n=te(t===!1),o=te(t);let i=!1;const r=e.touchDevice&&!navigator.userAgent.toLowerCase().includes("android"),s=((j=(O=e.raw.value)==null?void 0:O.imgs)==null?void 0:j.filter(Boolean))??[];let l=e.isAutoShow!==!1?e.page.value:s.length?Kg(s):void 0,a=s.map(M=>({src:M})),u,c;const d=new Map,f=({src:M,el:G})=>{const C=G??M;return C?d.get(C):void 0},h=te(s.map(M=>({src:M,isLoading:!0,hasError:!1}))),w=()=>{const M=[];a.forEach(G=>{const{src:C,el:ee}=G,W=ee??C,S=W?d.get(W):void 0;(W&&!(S!=null&&S.invalid)||G.parentEl)&&M.push(S)}),h.value=M};let y=setTimeout(e.onTimeout,2e4);const $=()=>{y&&(clearTimeout(y),y=void 0)};let k=0,B=0;const A=4,b=new Ng({onChanged(M,G){const C=M.el??M.src;if(!C||(d.set(C,G),w(),G.isLoading))return;if(G.hasError){if(c||o.value!==void 0)return;c=setTimeout(()=>{c=void 0,o.value===void 0&&e.onError("Failed to load images")},3e3);return}const{size:ee,invalid:W}=G;if(!(!ee||W)){if(!o.value&&B<A){const S=i?a:a.filter(({el:ae,src:he})=>he||!(ae&&ae instanceof HTMLImageElement&&!d.has(ae)));let x=S.indexOf(M);if(i&&x>4||x===-1&&(M.el&&(x=S.findIndex(ae=>ae.el===M.el)),x===-1))return;const U=x>Math.min(1,S.length-3)&&x<Math.max(S.length-2,3),K=ee.width/ee.height;K>2&&k++;const D=K<.5||k>=A,fe=!D&&.65<K&&K<.75;fe&&B++,o.value!==D&&(U||D)&&(o.value=D),U&&n.value!=fe&&(n.value=!0),o.value===void 0&&fe&&B===A&&(o.value=!1)}Z()}}}),g=new Rg({download:async M=>{!(M.el&&d.has(M.el))&&!(M.src&&d.has(M.src))&&await b.download(M)}}),E=()=>{g.run({items:a,activeIndex:Math.min(a.length-1,Math.floor(e.page.value))})},L=new xr;if(s.length)E();else{let M=!1;u=new qg({spec:e.spec,async onChanged(G){var C;if(a=G,w(),!e.raw.value&&!G.length){e.onError("no_img");return}(C=e.spec)!=null&&C.imgDivs&&!M&&e.isAutoShow!==!1&&e.page.value&&(M=!0,L.scrollTo({rawImages:G,page:e.page.value,skipIfVisible:!0,fallbackScrollEl:r?document.body:document.documentElement,isScrollDown:!0}),await oo(1)),l===void 0&&e.isAutoShow===!1&&(l=Ma(G)),E()}})}Pi(()=>{b.dispose(),g.dispose(),u==null||u.dispose(),c&&clearTimeout(c),L.dispose(),i&&L.scrollTo({rawImages:a,page:e.page.value,fallbackScrollEl:document.documentElement,isScrollExact:!0})});function Z(){if(i||o.value===void 0||l===void 0)return;const M=Math.max(0,Math.min(l,a.length)),G=Math.min(Math.floor(M),a.length-1);if(G>=1){const ee=a[G];if(!ee||!f(ee)){e.isAutoShow&&L.scrollTo({rawImages:a,page:G,fallbackScrollEl:r?document.body:document.documentElement,isScrollDown:!0});return}for(let W=G;W<a.length;W++){const S=f(a[W]);if(!S)return;if(!S.invalid){if(!S.size&&!S.hasError)return;break}}for(let W=G-1;W>=0;W--){const{src:S,el:x}=a[W],U=x??S;if(!U)break;const K=d.get(U);if(!K)return;if(!K.invalid){if(!K.size&&!K.hasError)return;break}}}if(i)return;i=!0,$(),e.onReady(M);let C=!0;de(()=>Math.floor(e.page.value),(ee,W)=>{ee===W&&!C||(L.scrollTo({rawImages:a,page:ee,isScrollDown:W===void 0||ee>W||a.length===1,skipIfVisible:C&&a.length>1,fallbackScrollEl:r?document.body:document.documentElement}),C=!1,W??(W=-1),E())},{immediate:!0})}return{asyncImgs:Q(()=>h.value),isWebtoon:Q(()=>o.value??!1),isManga:Q(()=>n.value)}}function Pa({touchDevice:e,isBusy:t,isPlaying:n,isIdle:o,hideControlsEvent:i,scrollEl:r,moveThreshold:s}){const l=te(!0);let a=!1,u=!1;const c={x:0,y:0};let d;Pt(()=>{d==null||d(),d=void 0});function f(k){if(i.value===nn.never||t.value&&l.value)return;const B=typeof k=="boolean"?k:!l.value;B!==l.value&&(l.value=B,!a&&!B&&(a=!0))}function h(){r.value&&(c.x=r.value.scrollLeft,c.y=r.value.scrollTop)}function w(){const k=i.value===nn.firstMove,B=r.value;if(!B)return;const A=Mn(()=>{if(!l.value){Yg(B)&&f(!0);return}if(k&&a)return;const b=Math.abs(B.scrollTop-c.y)||Math.abs(B.scrollLeft-c.x),g=s??(k?c.y===0?300:200:150);b>g&&f(!1)},100);B.addEventListener("scroll",A),d=()=>{B.removeEventListener("scroll",A)}}function y(){switch(d==null||d(),d=void 0,i.value){case nn.onLoad:a||f(!1);break;case nn.firstMove:w();break;case nn.move:w();break;case nn.never:l.value||(l.value=!0);break}}function $(){u||(u=!0,h(),y(),e&&de(Yi(),B=>{B==="hidden"&&!n.value&&!l.value&&f(!0)}),de(t,k=>{k&&!l.value&&f()}),de(n,k=>{k||f(!0)}),de(o,k=>{n.value&&f(!k)}),de(l,k=>{k&&h()}),de(i,()=>y()),de(r,()=>y()))}return{visible:Q(()=>l.value),toggle:f,activate:$}}function Yg(e){const t=Math.max(0,e.scrollTop),n=Math.abs(e.scrollLeft);if(n<10&&t<10)return!0;const{scrollHeight:o,clientHeight:i}=e;if(o>i)return t>o-i-10;const{scrollWidth:s,clientWidth:l}=e;return s>l&&n>s-l-10}function Xg(e,t,n){return Q(()=>t.value?Ea(e.value,n.value):e.value.map((o,i)=>[{img:o,index:i}]))}function Ea(e,t,n=0){if(e.length===0)return[];const o=e.slice(0,2),i=o.some(s=>(s==null?void 0:s.size)&&s.size.width>s.size.height),r=i||t?[o[0]]:o;return[r.map((s,l)=>({img:s,index:n+l})),...Ea(e.slice(r.length),t&&i,n+r.length)]}const _r=40;function Gg({page:e,asyncImgs:t,direction:n,style:o,isLongStrip:i,isVertical:r,isRTL:s,spaceTop:l,scrollEl:a,isWebtoon:u,interferePlayer:c,onChangedPage:d,onFinished:f}){let h=!1,w=!1,y,$=!1,k,B;const A=gt(O,300),b=Mn(()=>{O(),A()},300);function g(){const x=new Promise(U=>{y=()=>{y=void 0,U()}});return Z(e.value,{smooth:!1,ensureLastImgVisibility:!0}),x}function E(){var x;w=!0,y==null||y(),j(),(x=a.value)==null||x.addEventListener("scroll",b),setTimeout(()=>{const{width:U,height:K}=mn();de(()=>`${K.value}-${U.value}`,L),de(o,L),de(n,L),de(()=>t.value,(D,fe)=>{!fe||D.length===fe.length||s.value&&L()})},300)}function L(){const x=a.value;if(!x)return;const U=Date.now();B=U;const{scrollWidth:K,scrollHeight:D}=x,fe=e.value,ae=Math.floor(fe),he=t.value[ae];en(20,10,async()=>{if(B!==U)return!0;if(x.scrollWidth===K&&x.scrollHeight===D)return;let ve=fe;if(he){const we=t.value.findIndex(Ae=>Ae===he||(Ae==null?void 0:Ae.src)===he.src);we!==-1&&ae!==we&&(ve=we+fe-ae)}return await Z(ve),!0})}async function Z(x,{smooth:U,ensureLastImgVisibility:K=!1}={smooth:!1}){return new Promise(D=>{const fe=a.value;if(!fe){D();return}h=!0;const ae=async()=>{await pt(),h=!1,w||E(),D()},he=Math.floor(x),ve=br(fe,he);if(!ve){ae();return}c(async()=>{await _(fe,!i.value&&U,async()=>{await S(fe,ve,{smooth:U,page:x,ensureLastImgVisibility:K})}),await ae()})})}async function _(x,U,K){U&&x.style.setProperty("scroll-snap-type","none"),await K(),U&&x.style.removeProperty("scroll-snap-type")}function O(){if(h)return;const x=G();x!==void 0&&x!==e.value&&d(x),j()}function j(){$||!$&&M()&&($=!0,f())}function M(){const x=a.value;if(!x)return!1;const U=!i.value||u.value?3:!r.value&&x.clientWidth>x.clientHeight?2.25:2.5;return r.value?x.scrollHeight-x.scrollTop<x.clientHeight*U:x.scrollWidth-(s.value?-x.scrollLeft:x.scrollLeft)<x.clientWidth*U}function G(){const x=C();return x?(+x.getAttribute("data-index")||0)+(i.value?ee(x):0):void 0}function C(){var U;if(k??(k=a.value.getRootNode()),!k)return;const x=(U=k.elementsFromPoint)==null?void 0:U.call(k,r.value||!i.value?window.innerWidth/2:s.value?window.innerWidth-_r:_r,r.value&&i.value?l.value||_r:window.innerHeight/2);if(x)for(let K=0;K<x.length;K++){const D=x[K];if(D.hasAttribute("data-index"))return D;if(D===a.value)break}}function ee(x){const U=x.getBoundingClientRect();return r.value?Math.abs(U.top-l.value)/U.height:s.value?Math.max(0,U.right-a.value.clientWidth)/U.width:Math.abs(U.left)/U.width}let W=!1;async function S(x,U,K){if(W)return;const D=U.getBoundingClientRect();if(!i.value){if(r.value){if(D.top<=0&&D.bottom>=x.clientHeight)return}else if(D.left<=0&&D.right>=x.clientWidth)return}W=!0;const fe=r.value?x.scrollTop:x.scrollLeft,ae=K.page,he=i.value?ae%1:0,ve=await en(30,10,async()=>{await oo();let De;if(!(U.offsetHeight<10))return i.value?r.value?De=U.offsetTop+he*U.offsetHeight-l.value:s.value?De=U.offsetLeft-x.clientWidth+U.offsetWidth-he*U.offsetWidth:De=U.offsetLeft+he*U.offsetWidth:r.value?De=U.offsetTop+(D.top>0?0:D.height-x.clientHeight):De=U.offsetLeft+(D.left>0?0:D.width-x.clientWidth),ae>.5&&Math.abs(De)<100?void 0:De})??0,we=K.ensureLastImgVisibility?r.value?Math.min(ve,x.scrollHeight-x.clientHeight*2):s.value?Math.max(ve,-(x.scrollWidth-x.clientWidth*2)):Math.min(ve,x.scrollWidth-x.clientWidth*2):ve;if(!K.smooth){r.value?x.scrollTop=we:x.scrollLeft=we,W=!1;return}const Ae=we-fe,at=30;let Je=0;return new Promise(De=>{(function Pn(){const p=Jg(Je,fe,Ae,at);r.value?x.scrollTop=p:x.scrollLeft=p,Je++,Je<=at?requestAnimationFrame(Pn):(De(),W=!1)})()})}return{init:g,goToPage:Z}}function Jg(e,t,n,o){return n*(Math.pow(e/o-1,3)+1)+t}class Qg{constructor(t){Pe(this,"player");Pe(this,"debounceStartPlayer");Pe(this,"isPlaying");Pe(this,"isIdle",te(!1));Pe(this,"onIdle");this.player=t.player,this.debounceStartPlayer=gt(()=>this.player.start(),100);const n=te(t.autoPlay||sessionStorage.getItem("mp:playing")==="true");this.isPlaying=Q({get:()=>n.value,set:o=>{n.value=o,sessionStorage.setItem("mp:playing",o?"true":"false")}}),this.onIdle=gt(()=>{this.isIdle.value=!0},t.touchDevice?2e3:1e3),this.awake(),t.touchDevice||_t(window,"mousemove",()=>this.awake()),je(()=>{t.touchDevice||de(Yi(),i=>{this.isPlaying.value&&(i==="visible"?this.player.start():this.player.stop())}),de(t.speed,()=>this.interfere()),de(t.isBusy,o=>{!o&&this.isIdle.value&&this.awake()})}),Pt(()=>this.stop())}activate(){this.isPlaying.value&&this.player.start()}toggle(){this.isPlaying.value?this.stop():this.start()}async interfere(t){this.isPlaying.value&&this.player.stop(),t&&(await pt(),await t()),this.isPlaying.value&&this.debounceStartPlayer()}stop(){this.isPlaying.value&&(this.isPlaying.value=!1,this.player.stop(),this.awake())}start(){this.isPlaying.value||(this.isPlaying.value=!0,this.player.start(),this.awake())}pause(){this.player.stop()}resume(){this.player.start()}awake(){setTimeout(()=>{this.isIdle.value=!1,this.onIdle()},30)}}class Ia extends Qg{getMaxOffset(t){return t.scrollHeight-t.clientHeight}getScrollOffset(t){return t.scrollTop}setScrollOffset(t,n){t.scrollTop+=n}constructor(t){let n,o;const{scrollEl:i,speed:r}=t;super({...t,player:{stop:()=>o==null?void 0:o(),start:()=>{const s=i.value;if(!this.isPlaying.value||!s)return;const l=this.getMaxOffset(s),a=this.getScrollOffset(s);if(l<=a){this.stop();return}o=()=>{n=Date.now(),o=void 0};const u=Date.now();n=u;const c=.1*r.value;let d=Date.now(),f=0;const h=()=>{if(n!==u)return;const w=Date.now(),y=w-d;d=w;const $=c*y+f;$>=1?(f=$%1,this.setScrollOffset(s,$-f)):f=$,setTimeout(h,1)};h()}}})}}class em extends Ia{constructor(n){super(n);Pe(this,"isLongStrip");Pe(this,"isVertical");Pe(this,"isRTL");const{isLongStrip:o,isVertical:i,isRTL:r}=n;this.isLongStrip=o,this.isVertical=i,this.isRTL=r,o!==void 0&&je(()=>{de(o,s=>{s||stop()})})}getMaxOffset(n){return this.isVertical.value?n.scrollHeight-n.clientHeight:n.scrollWidth-n.clientWidth}getScrollOffset(n){return this.isVertical.value?n.scrollTop:this.isRTL.value?-n.scrollLeft:n.scrollLeft}setScrollOffset(n,o){n[this.isVertical.value?"scrollTop":"scrollLeft"]+=o*(this.isRTL.value?-1:1)}start(){var n;((n=this.isLongStrip)==null?void 0:n.value)!==!1&&super.start()}}function tm(e){return new em(e)}function nm({speed:e,fontSize:t,lineHeight:n,...o}){const i=mn().width;return new Ia({...o,speed:Q(()=>{const r=900/Math.min(900,i.value)/3.5,s=t.value/48*1.75,l=n.value/96*1.75,a=r*s*l;return e.value*a})})}const om={key:3,class:"fixed inline-block left-1/2 -translate-x-1/2 bottom-0 p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3"},Oa=ge({inheritAttrs:!1,__name:"GearSecond",props:{chapterNavData:{type:Object},busy:{type:Boolean},defaultPreferences:{type:Object},immediate:{type:Boolean},appVersion:{type:String},raw:{type:Object},spec:{type:Object},siteMeta:{type:null},page:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},entryId:{type:String},isAutoShow:{type:Boolean},tourEnabled:{type:Boolean},offlineMode:{type:Boolean}},emits:["clickEntryButton","hideReader","openHelpScreen","error","crash","timeout","ready","pageChanged","playingChanged","dispose","openEntry","addEntry","finished","getHiddenChapters","hapticFeedback","pressedBack","selectChapter","openDefaultPreferences","defaultPreferencesChanged","controlsVisibilityChanged"],setup(e,{emit:t}){var R,F;const n=e,o=t,i=te(!1),r=te(!1),s=Q(()=>n.busy),l=Q(()=>n.page),a=Q(()=>n.immediate||i.value?n.spaceTop??0:0),u=Q(()=>!n.touchDevice&&C.isIdle.value&&!n.busy&&!E.value),{asyncImgs:c,isWebtoon:d}=Zg({raw:Q(()=>n.raw),spec:n.spec,page:l,touchDevice:n.touchDevice,isAutoShow:n.isAutoShow,async onReady(I){ae(I),i.value=!0},onError:()=>o("error"),onTimeout:()=>o("timeout")}),{direction:f,style:h,isRTL:w,isDouble:y,isVertical:$,isLongStrip:k,gap:B,speed:A,zoom:b,breakFirst:g}=xh({touchDevice:n.touchDevice,isWebtoon:d,titleName:(R=n.raw)==null?void 0:R.title.name,defaultPreferences:Q(()=>n.defaultPreferences)}),E=te(!1),L=Xg(c,y,g),Z=Q(()=>c.value.length),_=Q(()=>l.value>=Z.value),O=te(null),j=te(null),M=Q(()=>{var I;return(I=j.value)==null?void 0:I.rootEl}),G=te(!1),C=tm({autoPlay:!n.tourEnabled&&(((F=n.defaultPreferences)==null?void 0:F.autoPlay)??!1),touchDevice:n.touchDevice,scrollEl:M,speed:A,isRTL:w,isVertical:$,isLongStrip:k,isBusy:s}),ee=Q({get(){return b.value},set(I){C.interfere(()=>{b.value=I})}}),W=Pa({touchDevice:n.touchDevice,isBusy:s,isPlaying:Q(()=>C.isPlaying.value),isIdle:Q(()=>C.isIdle.value),hideControlsEvent:Q(()=>n.defaultPreferences.hideControlsEvent),scrollEl:M}),S=W.visible,x=Gg({page:l,asyncImgs:c,style:h,direction:f,isLongStrip:k,isVertical:$,isRTL:w,spaceTop:a,isWebtoon:d,scrollEl:Q(()=>{var I;return(I=j.value)==null?void 0:I.rootEl}),interferePlayer:I=>C.interfere(I),onChangedPage:ae,onFinished:()=>o("finished")}),U=Q(()=>Math.floor(l.value)),K=Q(()=>k.value?l.value:y.value?Pn():Math.floor(l.value)),D=()=>C.interfere(()=>oo(100));$t({onKeyDown:I=>{if(n.tourEnabled)return!0;const T=k.value&&$.value,H=k.value&&!$.value,N=!k.value&&$.value,se=!k.value&&!$.value;switch(I.key){case" ":I.preventDefault(),k.value||p();break;case"ArrowUp":case"PageUp":T?D():N&&U.value!==0&&(I.preventDefault(),Je());break;case"ArrowDown":case"PageDown":T?D():N&&!_.value&&(I.preventDefault(),De());break;case"ArrowLeft":H?D():se?(I.preventDefault(),Ae()):$.value&&we();break;case"ArrowRight":H?D():se?(I.preventDefault(),at()):$.value&&ve();break}},onKeyUp:I=>{switch(I.key){case"b":g.value=!g.value;break}}}),de(C.isPlaying,I=>{o("playingChanged",I)}),de(S,I=>{o("controlsVisibilityChanged",I)});async function fe(){await x.init(),o("ready"),r.value=!0,W.activate(),C.activate()}function ae(I){if(l.value===I)return;const T=c.value.length;if(I<0||I>=T+1)return;const H=l.value;if(o("pageChanged",I),I<.01&&H>I){C.awake();return}}function he(){!n.touchDevice&&!k.value&&x.goToPage(U.value,{smooth:!0})}function ve(I=!1){var T,H;(H=(T=n.chapterNavData)==null?void 0:T.next)==null||H.call(T,I)}function we(I=!1){var T,H;(H=(T=n.chapterNavData)==null?void 0:T.prev)==null||H.call(T,I)}function Ae(){w.value?De():Je()}function at(){w.value?Je():De()}function Je(){var H;const I=L.value,T=_.value?I[I.length-1][0].index:(H=I[Pn()-1])==null?void 0:H[0].index;T!==void 0?x.goToPage(T):we()}function De(){var I,T;if(_.value)ve();else{const H=((T=(I=L.value[Pn()+1])==null?void 0:I[0])==null?void 0:T.index)??c.value.length;x.goToPage(H)}}function Pn(){const I=U.value,T=L.value.findIndex(H=>H.some(({index:N})=>N===I));return T===-1?L.value.length-1:T}function p(I){W.toggle(I)}function m(){if(C.isPlaying.value){S.value||!n.touchDevice?C.stop():(C.awake(),W.toggle(!0));return}W.toggle()}function P(){C.stop(),o("clickEntryButton")}function q(){W.toggle(!1),C.isPlaying.value&&C.stop(),o("openHelpScreen")}return(I,T)=>e.immediate||i.value?(v(),ie(hr,{key:0,ref_key:"gearLayout",ref:O,loading:!r.value,immediate:!!e.immediate,"hide-cursor":u.value,class:"text-stone-100",onClick:T[21]||(T[21]=Be(()=>{},["stop"]))},{default:oe(()=>{var H,N,se,ne;return[i.value?(v(),ie(ga,{key:0,ref_key:"body",ref:j,zoom:ee.value,"onUpdate:zoom":T[1]||(T[1]=J=>ee.value=J),zooming:E.value,"onUpdate:zooming":T[2]||(T[2]=J=>E.value=J),page:l.value,"page-index":U.value,pages:X(L),"total-imgs":X(c).length,direction:X(f),gap:X(B),"is-long-strip":X(k),isRTL:X(w),"is-double":X(y),"is-vertical":X($),"space-top":a.value||0,busy:s.value,"play-controller":X(C),"touch-device":e.touchDevice,"pinch-to-zoome":((H=e.defaultPreferences)==null?void 0:H.pinchToZoom)??!0,"tap-zone":(N=e.defaultPreferences)==null?void 0:N.tapZone,"controls-visible":X(S),onReady:fe,onPrev:Je,onNext:De,onClick:m,onDragEnd:he,onWheelPassive:T[3]||(T[3]=()=>X(C).interfere())},Ei({_:2},[i.value&&X(c).length?{name:"end",fn:oe(()=>{var J,ce;return[V(Ji,{"has-next":!!((J=e.chapterNavData)!=null&&J.next),"offline-mode":!!e.offlineMode,seconds:((ce=e.defaultPreferences)==null?void 0:ce.autoNextSeconds)??5,"show-add-button":X(b)===1&&!e.entryId&&!!e.raw&&!e.offlineMode,onNext:ve,onAddToLibrary:P,onHide:T[0]||(T[0]=()=>o("hideReader"))},null,8,["has-next","offline-mode","seconds","show-add-button"])]}),key:"0"}:void 0]),1032,["zoom","zooming","page","page-index","pages","total-imgs","direction","gap","is-long-strip","isRTL","is-double","is-vertical","space-top","busy","play-controller","touch-device","pinch-to-zoome","tap-zone","controls-visible"])):le("",!0),V(yr,{modelValue:G.value,"onUpdate:modelValue":T[10]||(T[10]=J=>G.value=J),"enable-help":"",name:(se=e.raw)==null?void 0:se.title.name,"space-top":a.value,"enable-default-preferences":!e.touchDevice||!!e.appVersion,onHelp:q,onMore:T[11]||(T[11]=()=>o("openDefaultPreferences"))},{"tab-preferences":oe(()=>[V(fa,{"enable-reset":!e.touchDevice||!!e.appVersion,webtoon:X(d),"reader-style":X(h),"onUpdate:readerStyle":T[4]||(T[4]=J=>ze(h)?h.value=J:null),direction:X(f),"onUpdate:direction":T[5]||(T[5]=J=>ze(f)?f.value=J:null),gap:X(B),"onUpdate:gap":T[6]||(T[6]=J=>ze(B)?B.value=J:null),speed:X(A),"onUpdate:speed":T[7]||(T[7]=J=>ze(A)?A.value=J:null),zoom:ee.value,"onUpdate:zoom":T[8]||(T[8]=J=>ee.value=J),"default-preferences":e.defaultPreferences},null,8,["enable-reset","webtoon","reader-style","direction","gap","speed","zoom","default-preferences"])]),"tab-default":oe(()=>[V(fr,{"model-value":e.defaultPreferences,"onUpdate:modelValue":T[9]||(T[9]=J=>o("defaultPreferencesChanged",J))},null,8,["model-value"])]),_:1},8,["modelValue","name","space-top","enable-default-preferences"]),r.value&&!_.value&&!e.tourEnabled?(v(),ie(aa,{key:1,direction:X(f),"tap-zone":(ne=e.defaultPreferences)==null?void 0:ne.tapZone},null,8,["direction","tap-zone"])):le("",!0),r.value&&!_.value?(v(),ie(gr,{key:2,playing:X(C).isPlaying.value},null,8,["playing"])):le("",!0),V(ca,{visible:X(S),"space-top":a.value},Ei({top:oe(()=>{var J;return[e.raw||e.offlineMode?(v(),ie(Qi,{key:0,"offline-mode":e.offlineMode,raw:e.raw,onClick:T[12]||(T[12]=()=>o("pressedBack"))},null,8,["offline-mode","raw"])):le("",!0),!e.touchDevice&&!e.offlineMode?(v(),ie(Go,{key:1,onClick:T[13]||(T[13]=()=>o("hideReader"))})):le("",!0),e.chapterNavData?(v(),ie(lr,{key:2,"touch-device":e.touchDevice,"chapter-spec":(J=e.spec)==null?void 0:J.chapter,data:e.chapterNavData,rtl:X(w),onGetHiddenChapters:T[14]||(T[14]=()=>o("getHiddenChapters")),onPrev:we,onNext:ve,onDialogOpened:T[15]||(T[15]=()=>X(W).toggle(!1))},null,8,["touch-device","chapter-spec","data","rtl"])):le("",!0)]}),"bottom-right":oe(()=>[!e.offlineMode&&e.raw?(v(),ie(er,{key:0,"entry-id":e.entryId,onClick:P},null,8,["entry-id"])):le("",!0),V(ir,{disabled:!i.value,onClick:T[16]||(T[16]=()=>G.value=!0)},null,8,["disabled"]),e.touchDevice?le("",!0):(v(),ie(rr,{key:1,onRequestFullScreen:T[17]||(T[17]=()=>{var J,ce;return(ce=(J=O.value)==null?void 0:J.rootEl)==null?void 0:ce.requestFullscreen()})})),X(k)?(v(),ie(or,{key:2,"tour-message":"Press here to play like a video",playing:X(C).isPlaying.value,disabled:!r.value,onClick:T[18]||(T[18]=()=>X(C).toggle())},null,8,["playing","disabled"])):le("",!0),X(y)?(v(),ie(Ge,{key:3,title:"Break 1st page (B)","data-tour":"Press here to separate the first page from double-page mode",disabled:!r.value,onClick:T[19]||(T[19]=()=>g.value=!X(g))},{default:oe(()=>[X(g)?(v(),ie(da,{key:0})):(v(),ie(ua,{key:1}))]),_:1},8,["disabled"])):le("",!0)]),progress:oe(()=>{var J,ce;return[((J=e.defaultPreferences)==null?void 0:J.progressSize)!==0&&!_.value?(v(),ie(mr,{key:0,value:K.value,total:X(L).length,"long-strip":X(k),height:((ce=e.defaultPreferences)==null?void 0:ce.progressSize)??2,rtl:X(w)},null,8,["value","total","long-strip","height","rtl"])):le("",!0)]}),default:oe(()=>[e.appVersion&&a.value&&!e.offlineMode?(v(),z("div",{key:0,class:"fixed top-0 left-0 right-0 bg-black bg-opacity-70 pointer-events-auto",style:Ce({height:`${a.value}px`})},null,4)):le("",!0)]),_:2},[X(L).length?{name:"bottom-left",fn:oe(()=>[V(pa,{"model-value":U.value,disabled:!r.value,pages:X(L),"total-imgs":X(c).length,"onUpdate:modelValue":X(x).goToPage},null,8,["model-value","disabled","pages","total-imgs","onUpdate:modelValue"])]),key:"0"}:void 0]),1032,["visible","space-top"]),X(S)||E.value?(v(),z("div",om,[V(Gn,{"enter-from-class":"opacity-0","leave-to-class":"opacity-0"},{default:oe(()=>[E.value||X(b)!==1?(v(),ie(ql,{key:0,zoom:ee.value,onClick:T[20]||(T[20]=Be(()=>ee.value=1,["stop"])),class:"duration-200"},null,8,["zoom"])):le("",!0)]),_:1})])):le("",!0),Se(I.$slots,"default")]}),_:3},8,["loading","immediate","hide-cursor"])):le("",!0)}}),im=Object.freeze(Object.defineProperty({__proto__:null,default:Oa},Symbol.toStringTag,{value:"Module"}));function rm({sel:e,heading:t,paraSel:n,useObfFont:o}){const i=["H1","H2","H3","H4","H5","H6","P","BLOCKQUOTE","PRE","CODE"],r=["BR","HR"],s=["BUTTON","FIGURE","IMG","SCRIPT","SELECT","INPUT","FORM","IFRAME","NAV","FOOTER","ASIDE","TABLE"],l=sm(e),a=lm(l),u=o?am(l):void 0,c=d(l);if(!c)return;return{el:c,isRTL:a,fontFamily:u};function d(w){var E;let y=0,$=!1,k=0,B=0,A=!1;const b=(E=g(w,i.includes(w.tagName)||!!n&&w.matches(n)))==null?void 0:E.node;if(!b)return;if(t){const L=document.createElement("h1");L.innerText=t,b.prepend(L)}return h(b),f(b),b;function g(L,Z=!1){var U;if(A)return;if(L.nodeType===Node.TEXT_NODE)return Z&&((U=L.textContent)!=null&&U.trim())?{node:L.cloneNode()}:void 0;if(L.nodeType!==Node.ELEMENT_NODE)return;const O=L.tagName;if(s.includes(O)||O==="A"&&($||!Z))return;if(r.includes(O))return Z?{node:document.createElement(O),isEmpty:!0}:{aborted:!0};if(L.getAttribute("aria-hidden")==="true"||!gn(L)||window.getComputedStyle(L).position==="fixed")return;const M=!!n&&L.matches(n),G=M||i.includes(O),C=Z||G,ee=[];if(Array.from(L.childNodes).forEach(K=>{if(A)return;const D=g(K,C);if(D!=null&&D.aborted)return;const fe=D==null?void 0:D.node;if(fe){if(B=D!=null&&D.isEmpty?B+1:0,B>2)return;ee.push(fe),$?k=0:++y>30&&($=!0)}else $&&++k>30&&(A=!0)}),!ee.length)return G?{node:document.createElement("br"),isEmpty:!0}:void 0;const S=document.createElement(M?"p":O==="BODY"?"div":O==="a"?"span":O),x=L.getAttribute("dir");return x&&x!=="auto"&&S.setAttribute("dir",x),ee.forEach(K=>S.appendChild(K)),{node:S}}}function f(w){za(w,y=>{if(y===w)return;const $=y.tagName;if(r.includes($)||i.includes($))return;const k=y.parentElement;if((k==null?void 0:k.childNodes.length)===1){Array.from(y.childNodes).forEach(b=>{k.appendChild(b)}),k.removeChild(y);return}y.childNodes.length===1&&y.replaceWith(y.childNodes[0])})}function h(w){let y=!1;const $=[];Sr(w,k=>i.includes(k.tagName)?[]:Array.from(k.children),k=>{const B=k.textContent.trim();if(!B)return!0;if(y)return!1;if(y=!$a(k),$.includes(B))return!0;if(y)return!1;$.push(B)}),Sr(w,k=>i.includes(k.tagName)?[]:Array.from(k.children).reverse(),k=>!k.textContent.trim()||$a(k))}}function $a(e){const t=e.nodeName;return t.length===2&&t.startsWith("H")}function sm(e){const t=(e??"main,article").split(",").filter(Boolean);for(const o of t){const i=document.querySelector(o);if(i)return i}const n=document.querySelector("p:has(+ p), h1, h2");if(n){let o=n;for(;o!==document.body;)o=o.parentElement;return o}return document.body}function lm(e,t){if(e.getAttribute("dir")==="rtl")return!0;const n=e.querySelector("p")||e.querySelector("div:not(:empty)")||e;return n.getAttribute("dir")==="rtl"?!0:window.getComputedStyle(n).direction==="rtl"}function am(e,t){const n=e.querySelector("p")||e.querySelector("div:not(:empty)")||e;return window.getComputedStyle(n).fontFamily}function za(e,t){Array.from(e.children).forEach(o=>{za(o,t)}),t(e)}function Sr(e,t,n){const o=t(e);let i=!1;for(let r=0;r<o.length;r++){const s=o[r],l=Sr(s,t,n);if(l!==void 0){if(!l)return!1;cm(s)}else i=!0}if(!i)return n(e)}function cm(e){var t;(t=e.parentNode)==null||t.removeChild(e)}const um={key:1,class:"h-14 sm:h-16 px-2 2xs:px-3 flex gap-1 2xs:gap-3 items-center"},dm={class:"md:fixed left-0 right-0 bottom-0"},fm={class:"p-2 2xs:px-3 sm:py-3 pb-6 md:pb-5 lg:pb-3 flex md:flex-col gap-4 justify-between items-center"},Da=ge({__name:"GearThirdControlsLayout",props:{visible:{type:Boolean},hideTopControls:{type:Boolean},spaceTop:{type:null}},setup(e){return(t,n)=>(v(),z(ye,null,[Y("div",{class:ue(["fixed left-0 right-0 top-0 bg-inherit z-30",{"opacity-0 pointer-events-none":!e.visible}])},[e.spaceTop?(v(),z("div",{key:0,style:Ce({height:`${e.spaceTop}px`})},null,4)):le("",!0),e.hideTopControls?le("",!0):(v(),z("div",um,[Se(t.$slots,"top-controls")]))],2),Y("div",{class:ue(["fixed left-0 right-0 bottom-0 md:left-auto z-30 bg-inherit md:bg-transparent",{"opacity-0 pointer-events-none":!e.visible}])},[Y("div",dm,[Se(t.$slots,"progress")]),Y("div",fm,[Se(t.$slots,"bottom-controls")])],2),Se(t.$slots,"default")],64))}}),pm=Object.freeze(Object.defineProperty({__proto__:null,default:Da},Symbol.toStringTag,{value:"Module"})),hm={},gm={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function mm(e,t){return v(),z("svg",gm,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M16 13q-.425 0-.712-.288T15 12t.288-.712T16 11h6q.425 0 .713.288T23 12t-.288.713T22 13zM4.675 15.425l-1.025 2.85q-.125.35-.4.538T2.625 19q-.575 0-.913-.487t-.137-1.038l4.4-11.725Q6.1 5.4 6.4 5.2t.65-.2h.9q.375 0 .663.2t.412.55L13.45 17.5q.2.55-.137 1.025T12.4 19q-.35 0-.65-.2t-.425-.55l-1-2.825zM5.4 13.4h4.2L7.55 7.6h-.1z"},null,-1)])])}const Aa=be(hm,[["render",mm]]),vm=Object.freeze(Object.defineProperty({__proto__:null,default:Aa},Symbol.toStringTag,{value:"Module"})),bm={},ym={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function wm(e,t){return v(),z("svg",ym,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"m4.675 15.425l-1.025 2.85q-.125.35-.4.538T2.625 19q-.575 0-.913-.487t-.137-1.038l4.4-11.725Q6.1 5.4 6.4 5.2t.65-.2h.9q.375 0 .663.2t.412.55L13.45 17.5q.2.55-.137 1.025T12.4 19q-.35 0-.65-.2t-.425-.55l-1-2.825zM5.4 13.4h4.2L7.55 7.6h-.1zM18 13h-2q-.425 0-.712-.288T15 12t.288-.712T16 11h2V9q0-.425.288-.712T19 8t.713.288T20 9v2h2q.425 0 .713.288T23 12t-.288.713T22 13h-2v2q0 .425-.288.713T19 16t-.712-.288T18 15z"},null,-1)])])}const La=be(bm,[["render",wm]]),xm=Object.freeze(Object.defineProperty({__proto__:null,default:La},Symbol.toStringTag,{value:"Module"})),ja=be(ge({__name:"NovelBody",props:{hideTopControls:{type:Boolean},progress:{type:Number},touchDevice:{type:Boolean},busy:{type:Boolean},spaceTop:{type:null},content:{type:null},rtl:{type:Boolean},titlePreferences:{type:Object},defaultPreferences:{type:Object}},emits:["ready","click","progressChanged","finished"],setup(e,{expose:t,emit:n}){const o=e,i=n,r=te(!1),s=te(),l=te(),a=Mn(()=>{const c=s.value;if(!c)return;const{clientHeight:d,scrollHeight:f,scrollTop:h}=c,w=Math.max(h,f-2*d);if(w<=0)i("progressChanged",1);else{const y=h/w;i("progressChanged",Math.max(0,Math.min(1,y)))}},30);t({scrollEl:s}),$t({onKeyDown(){var c;o.busy||(c=s.value)==null||c.focus()}}),je(()=>{de(()=>o.content,d=>{const f=l.value;f&&(Array.from(f.children).forEach(h=>{f.removeChild(h)}),f.appendChild(d),setTimeout(()=>{if(s.value){const{progress:w}=o;w&&u(w)}r.value=!0,i("ready")}))},{immediate:!0});const c=mn();de(()=>{const{fontFamily:d,fontSize:f,lineHeight:h}=o.titlePreferences;return`${d}-${f}-${h}-${c.width.value}`},async()=>{const d=o.progress;await pt(),u(d)})});function u(c){const d=s.value;d&&(d.scrollTop=c*(d.scrollHeight-2*d.clientHeight))}return(c,d)=>(v(),z("div",{ref_key:"scrollContainer",ref:s,tabindex:"0",class:ue(["novel-body",{"scrollbar-sm":!e.touchDevice,"scrollbar-none":e.touchDevice,"opacity-0":!r.value,"pt-16 sm:pt-18 md:pt-20":!e.hideTopControls,"pt-5 sm:pt-9 md:pt-12":e.hideTopControls}]),style:Ce({fontFamily:e.titlePreferences.fontFamily,"--font-size":`${e.titlePreferences.fontSize}px`,"--line-height":`${e.titlePreferences.lineHeight}px`,"--space-top":e.spaceTop?`${e.spaceTop}px`:void 0}),onClick:d[0]||(d[0]=()=>i("click")),onScroll:d[1]||(d[1]=(...f)=>X(a)&&X(a)(...f))},[Y("div",kn({ref_key:"contentContainer",ref:l,class:"novel-body__content"},e.rtl?{dir:"rtl"}:{}),null,16),Se(c.$slots,"end")],38))}}),[["styles",['.novel-body{top:0;right:0;bottom:0;left:0;overflow-wrap:break-word;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;padding-left:32px;padding-right:32px;position:fixed}.novel-body:focus{outline:2px solid transparent;outline-offset:2px}@media (min-width:640px){.novel-body{padding-left:48px;padding-right:48px}}@media (min-width:768px){.novel-body{padding-left:56px;padding-right:56px}}@media (min-width:1024px){.novel-body{padding-left:64px;padding-right:64px}}@media (min-width:1280px){.novel-body{padding-left:80px;padding-right:80px}}.novel-body{font-size:var(--font-size);letter-spacing:.01em;line-height:var(--line-height)}.novel-body:before{content:"";display:block;height:var(--space-top,0)}.novel-body__content{margin-left:auto;margin-right:auto;max-width:768px;min-height:100%}.novel-body hr{--tw-border-opacity:1;border-color:rgb(87 83 78/var(--tw-border-opacity,1));margin:calc(var(--line-height)*.5) 0}.novel-body h1,.novel-body h2,.novel-body h3,.novel-body h4,.novel-body h5,.novel-body h6{font-weight:500}.novel-body h1{font-size:calc(var(--font-size)*1.5);line-height:calc(var(--font-size)*.5 + var(--line-height))}.novel-body h2{font-size:calc(var(--font-size)*1.25);line-height:calc(var(--font-size)*.25 + var(--line-height))}.novel-body h3{font-size:calc(var(--font-size)*1.125);line-height:calc(var(--font-size)*.125 + var(--line-height))}.novel-body h5,.novel-body h6,.novel-body p{font-size:inherit;line-height:inherit}.novel-body blockquote,.novel-body figure,.novel-body h1,.novel-body h2,.novel-body h3,.novel-body h4,.novel-body h5,.novel-body h6,.novel-body img,.novel-body ol,.novel-body p,.novel-body ul{margin-bottom:calc(var(--line-height)*.5)}.novel-body pre{background-color:transparent;border-style:none;display:block;font-family:inherit;margin:0;padding:0;white-space:normal}']]]),_m=Object.freeze(Object.defineProperty({__proto__:null,default:ja},Symbol.toStringTag,{value:"Module"})),Ba=ge({inheritAttrs:!1,__name:"GearThird",props:{chapterNavData:{type:Object},busy:{type:Boolean},defaultPreferences:{type:Object},immediate:{type:Boolean},appVersion:{type:String},raw:{type:Object},spec:{type:Object},siteMeta:{type:null},page:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},entryId:{type:String},isAutoShow:{type:Boolean},tourEnabled:{type:Boolean},offlineMode:{type:Boolean}},emits:["clickEntryButton","hideReader","openHelpScreen","error","crash","timeout","ready","pageChanged","playingChanged","dispose","openEntry","addEntry","finished","getHiddenChapters","hapticFeedback","pressedBack","selectChapter","openDefaultPreferences","defaultPreferencesChanged","controlsVisibilityChanged"],setup(e,{emit:t}){var G,C,ee,W,S,x,U;const n=e,o=t,i=te(null),r=((G=n.raw)==null?void 0:G.novel)??rm({sel:(C=n.spec)==null?void 0:C.content,heading:(ee=n.raw)==null?void 0:ee.name,paraSel:(W=n.spec)==null?void 0:W.para});r===void 0&&o("error");const s=te(r==null?void 0:r.el),l=te(!!(r!=null&&r.isRTL)),a=te(!1),u=te(!1),c=Q(()=>n.page),d=Q(()=>n.busy),f=te(null),h=Q(()=>{var K;return(K=f.value)==null?void 0:K.scrollEl}),w=(x=(S=n.raw)==null?void 0:S.title)==null?void 0:x.name,y=w?ra(w):location.hostname,$=tf(`mpr:${y}`,{}),k=Q({get(){var ae,he;const K=n.defaultPreferences,D=((ae=$.value)==null?void 0:ae.fontSize)??K.fontSize,fe=Math.max(D,((he=$.value)==null?void 0:he.lineHeight)??K.lineHeight);return{fontFamily:K.fontFamily,speed:K.speed,...$.value,contrast:K.contrast,fontSize:D,lineHeight:fe}},set(K){const D={...K},fe=n.defaultPreferences;Object.keys(D).forEach(ae=>{D[ae]===fe[ae]&&delete D[ae]}),$.value=D}}),B=nm({isBusy:d,speed:Q(()=>k.value.speed),fontSize:Q(()=>k.value.fontSize),lineHeight:Q(()=>k.value.lineHeight),autoPlay:!!((U=n.defaultPreferences)!=null&&U.autoPlay),touchDevice:n.touchDevice,scrollEl:h}),A=Q(()=>!n.touchDevice&&B.isIdle.value&&!d.value),b=Pa({touchDevice:n.touchDevice,moveThreshold:50,isBusy:d,isPlaying:Q(()=>B.isPlaying.value),isIdle:Q(()=>B.isIdle.value),hideControlsEvent:Q(()=>n.defaultPreferences.hideControlsEvent),scrollEl:h}),g=b.visible;de(B.isPlaying,K=>{o("playingChanged",K)}),de(g,K=>{o("controlsVisibilityChanged",K)}),E(document.documentElement),E(document.body);function E(K){const D=K.style.getPropertyValue("overflow");D!=="hidden"&&(K.style.setProperty("overflow","hidden","important"),Pt(()=>{D?K.style.setProperty("overflow",D):K.style.removeProperty("overflow")}))}function L(){o("ready"),b.activate(),B.activate()}function Z(){B.stop(),o("clickEntryButton")}function _(K){u.value=K}function O(){if(B.isPlaying.value){g.value||!n.touchDevice?B.stop():(B.awake(),b.toggle(!0));return}b.toggle()}function j(K){K!==n.page&&(o("pageChanged",Math.min(1,K)),K>=1&&o("finished"))}function M(K){const D=k.value.fontSize+K;D>48||D<10||(k.value={...k.value,fontSize:D,lineHeight:Math.max(10,Math.min(96,Math.round(k.value.lineHeight/k.value.fontSize*D)))})}return(K,D)=>s.value?(v(),ie(hr,{key:0,ref_key:"gearLayout",ref:i,immediate:"","hide-cursor":A.value,class:"bg-stone-900",style:Ce({color:`rgba(255, 255, 255, ${e.defaultPreferences.contrast})`})},{default:oe(()=>{var fe;return[V(ja,{ref_key:"body",ref:f,progress:c.value,"touch-device":e.touchDevice,busy:d.value,"space-top":e.spaceTop,content:s.value,rtl:l.value,"title-preferences":k.value,"default-preferences":e.defaultPreferences,"hide-top-controls":!e.raw,onClick:O,onProgressChanged:j,onReady:L},{end:oe(()=>{var ae,he;return[V(Ji,{"has-next":!!((ae=e.chapterNavData)!=null&&ae.next),"offline-mode":!!e.offlineMode,seconds:((he=e.defaultPreferences)==null?void 0:he.autoNextSeconds)??5,onNext:D[0]||(D[0]=()=>{var ve,we;return(we=(ve=e.chapterNavData)==null?void 0:ve.next)==null?void 0:we.call(ve,!1)}),onVisibilityChanged:_,onHide:D[1]||(D[1]=()=>o("hideReader")),onFinished:D[2]||(D[2]=()=>o("finished"))},null,8,["has-next","offline-mode","seconds"])]}),_:1},8,["progress","touch-device","busy","space-top","content","rtl","title-preferences","default-preferences","hide-top-controls"]),!e.touchDevice&&!e.raw&&!e.offlineMode?Re((v(),ie(Go,{key:0,class:"hidden md:inline-block fixed left-3 top-2",transparent:"",onClick:D[3]||(D[3]=()=>o("hideReader"))},null,512)),[[nd,X(g)]]):le("",!0),V(Da,{visible:X(g),"hide-top-controls":!e.raw,"space-top":e.spaceTop},{"top-controls":oe(()=>{var ae;return[e.raw||e.offlineMode?(v(),ie(Qi,{key:0,"offline-mode":e.offlineMode,raw:e.raw,transparent:"",onClick:D[4]||(D[4]=()=>o("pressedBack"))},null,8,["offline-mode","raw"])):le("",!0),e.raw&&!e.touchDevice&&!e.offlineMode?(v(),ie(Go,{key:1,transparent:"",onClick:D[5]||(D[5]=()=>o("hideReader"))})):le("",!0),e.chapterNavData?(v(),ie(lr,{key:2,transparent:"","touch-device":e.touchDevice,"chapter-spec":(ae=e.spec)==null?void 0:ae.chapter,data:e.chapterNavData,rtl:l.value,onGetHiddenChapters:D[6]||(D[6]=()=>o("getHiddenChapters")),onPrev:D[7]||(D[7]=he=>{var ve,we;return(we=(ve=e.chapterNavData)==null?void 0:ve.prev)==null?void 0:we.call(ve,he)}),onNext:D[8]||(D[8]=he=>{var ve,we;return(we=(ve=e.chapterNavData)==null?void 0:ve.next)==null?void 0:we.call(ve,he)}),onDialogOpened:D[9]||(D[9]=()=>X(b).toggle(!1))},null,8,["touch-device","chapter-spec","data","rtl"])):le("",!0)]}),"bottom-controls":oe(()=>[!e.offlineMode&&e.raw?(v(),ie(er,{key:0,"entry-id":e.entryId,transparent:"",onClick:Z},null,8,["entry-id"])):le("",!0),V(Ge,{transparent:"",onClick:D[10]||(D[10]=()=>M(-1))},{default:oe(()=>[V(Aa)]),_:1}),V(Ge,{transparent:"",onClick:D[11]||(D[11]=()=>M(1))},{default:oe(()=>[V(La)]),_:1}),V(ir,{transparent:"",onClick:D[12]||(D[12]=()=>a.value=!0)}),e.touchDevice?le("",!0):(v(),ie(rr,{key:1,transparent:"",onRequestFullScreen:D[13]||(D[13]=()=>{var ae,he;return(he=(ae=i.value)==null?void 0:ae.rootEl)==null?void 0:he.requestFullscreen()})})),V(or,{transparent:"","tour-message":"Press here to start listening",playing:X(B).isPlaying.value,class:"order-2 md:order-4",onClick:D[14]||(D[14]=()=>X(B).toggle())},null,8,["playing"])]),progress:oe(()=>{var ae,he;return[((ae=e.defaultPreferences)==null?void 0:ae.progressSize)!==0?(v(),ie(mr,{key:0,value:c.value,height:((he=e.defaultPreferences)==null?void 0:he.progressSize)??2,rtl:l.value,opacity:e.defaultPreferences.contrast},null,8,["value","height","rtl","opacity"])):le("",!0)]}),_:1},8,["visible","hide-top-controls","space-top"]),u.value?le("",!0):(v(),ie(gr,{key:1,playing:X(B).isPlaying.value},null,8,["playing"])),V(yr,{modelValue:a.value,"onUpdate:modelValue":D[18]||(D[18]=ae=>a.value=ae),name:(fe=e.raw)==null?void 0:fe.title.name,"space-top":(e.spaceTop??0)+80,"enable-default-preferences":!e.touchDevice||!!e.appVersion,onMore:D[19]||(D[19]=()=>o("openDefaultPreferences"))},{"tab-preferences":oe(()=>[V(dr,{modelValue:k.value,"onUpdate:modelValue":D[15]||(D[15]=ae=>k.value=ae),"default-preferences":e.defaultPreferences,"enable-reset":!e.touchDevice||!!e.appVersion,onReset:D[16]||(D[16]=()=>$.value=null)},null,8,["modelValue","default-preferences","enable-reset"])]),"tab-default":oe(()=>[V(fr,{"is-novel":"","model-value":e.defaultPreferences,"onUpdate:modelValue":D[17]||(D[17]=ae=>o("defaultPreferencesChanged",ae))},null,8,["model-value"])]),_:1},8,["modelValue","name","space-top","enable-default-preferences"]),Se(K.$slots,"default")]}),_:3},8,["hide-cursor","style"])):le("",!0)}}),Sm=Object.freeze(Object.defineProperty({__proto__:null,default:Ba},Symbol.toStringTag,{value:"Module"}));function km({raw:e,spec:t,siteMeta:n,offlineMode:o,onSelect:i}){var j,M,G;const{vol:r,inferVol:s,chap:l,title:a,slug:u,basePath:c}=e,d=typeof(t==null?void 0:t.chapter)=="string"?{sel:t.chapter}:t==null?void 0:t.chapter;let f=-1;async function h(C,ee){if(o){i({...C});return}if(C.slug){w(C.slug,ee);return}if(C.elIndex===void 0||!(d!=null&&d.sel))return;let W=null;document.querySelector(d.sel)||(d!=null&&d.trigger&&(W=document.querySelector(d.trigger)),W&&(io(W),await new Promise(x=>setTimeout(()=>x(),50))));const S=d&&d.sel&&!d.url?document.querySelectorAll(d.sel):void 0;S!=null&&S[C.elIndex]&&(io(S[C.elIndex]),W&&document.querySelector(d.sel)&&io(W))}function w(C,ee){const W=Cm(c,C,(n==null?void 0:n.trailing)??!0);ee?window.open(W,"_blank","noopener"):location.href=W}function y(C){const ee=b[C];return ee?W=>h(ee,W):void 0}function $(C,ee,W){if(ee)w(ee,W);else if(C){const S=document.querySelector(C);S&&io(S,{preventDefault:!1})}}const k=r??s,B=d==null?void 0:d.url,A=((j=a.chapters)==null?void 0:j.filter(C=>C.slug||!B&&C.elIndex!==void 0))??[],b=A.length>1?A:[],g=(M=e.prev)==null?void 0:M.slug,E=(G=e.next)==null?void 0:G.slug,L=t!=null&&t.prev&&typeof t.prev!="string"?t.prev.btn??t.prev.sel:void 0,Z=t!=null&&t.next&&typeof t.next!="string"?t.next.btn??t.next.sel:void 0;let _=g||L&&!b.length&&document.body.querySelector(L)?C=>$(L,g,C):void 0,O=E||Z&&!b.length&&document.body.querySelector(Z)?C=>$(Z,E,C):void 0;if(b.length){if(B&&(f=b.findIndex(C=>C.slug===e.slug)),f===-1&&(f=b.findIndex(C=>(C.vol??C.inferVol)===k&&C.chap===l)),B&&f===-1&&(f=b.findIndex(C=>C.slug&&u.startsWith(`${C.slug}-`)&&u.length-C.slug.length>3)),f!==-1)_??(_=y(f+1)),O??(O=y(f-1));else if(!g&&!E){const C=b.findIndex(ee=>{const W=ee.vol??ee.inferVol;return k===void 0||W===void 0||k===W?ee.chap<l:W<k});C!==-1?(_=y(C),O=y(C-1)):O=y(b.length-1)}}return{activeIndex:f,activeLabel:Na({vol:r,chap:l}),prev:_,next:O,chapters:b.map(C=>({label:Na(C),select:ee=>h(C,ee)}))}}function Na({vol:e,chap:t}){return e==null?`Ch.${t}`:`Vol.${e} ch.${t}`}function Cm(e,t,n){const o=!t||t.includes("//")||t.startsWith("/")?t:"/"+[...e.split("/"),...t.split("/")].filter(Boolean).join("/"),[i,r]=(o.includes("//")?o:location.origin+o).split("?");return[i.endsWith("/")===n?i:n?i+"/":i.substring(0,-1),r].filter(Boolean).join("?")}function Tm(e){return e instanceof Error?JSON.stringify(e,Object.getOwnPropertyNames(e)):e}const Va=be(ge({inheritAttrs:!1,__name:"App",props:{immediate:{type:Boolean},appVersion:{type:String},raw:{type:Object},spec:{type:Object},siteMeta:{type:null},page:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},entryId:{type:String},defaultPreferences:{type:Object},isAutoShow:{type:Boolean},tourEnabled:{type:Boolean},offlineMode:{type:Boolean}},emits:["error","crash","timeout","ready","pageChanged","playingChanged","dispose","openEntry","addEntry","finished","getHiddenChapters","hapticFeedback","pressedBack","selectChapter","openDefaultPreferences","defaultPreferencesChanged","controlsVisibilityChanged"],setup(e,{emit:t}){var E,L,Z;const n=e,o=t;let i=!1,r=0;ys((_,O,j)=>{if(!i){i=!0;const G=`(3.5.0) ${(O==null?void 0:O.$options.name)??(O==null?void 0:O.$options.__name)??(O==null?void 0:O.$options.__file)}.${j}: ${Tm(_)}`;o("crash",G)}return!1});const s=te(n.raw?n.raw.contentType??Kt.manga:void 0);s.value===void 0&&Ed(((E=n.spec)==null?void 0:E.content)??"body",{paraSel:(L=n.spec)==null?void 0:L.para,include:(Z=n.siteMeta)==null?void 0:Z.contentTypes,timeoutMs:3e3}).then(_=>{_?s.value=_:o("error")});const l=te(!1),a=te(n.tourEnabled),u=lf({touchDevice:n.touchDevice}),c=df(n.page,n.isAutoShow),d=Q(()=>n.raw?km({raw:n.raw,spec:n.spec,siteMeta:n.siteMeta,offlineMode:n.offlineMode,onSelect:_=>o("selectChapter",_)}):void 0);uf().addListener({onKeyDown:_=>{switch(_.key){case"Escape":_.preventDefault();break}},onKeyUp:_=>{switch(_.key){case"h":b();break}}}),af(()=>o("hapticFeedback"));const h=gt(_=>o("pageChanged",_),300),w=te(y(n.defaultPreferences));de(()=>n.defaultPreferences,_=>w.value=y(_));function y(_){const O=(_==null?void 0:_.fontSize)??16,j=Math.max(O,(_==null?void 0:_.lineHeight)??28);return{..._,speed:(_==null?void 0:_.speed)??1,progressSize:(_==null?void 0:_.progressSize)??2,autoNextSeconds:(_==null?void 0:_.autoNextSeconds)??5,hideControlsEvent:(_==null?void 0:_.hideControlsEvent)??nn.firstMove,autoPlay:(_==null?void 0:_.autoPlay)??!1,pinchToZoom:(_==null?void 0:_.pinchToZoom)??!0,readerStyle:(_==null?void 0:_.readerStyle)??Dt.longStrip,direction:(_==null?void 0:_.direction)??tt.vertical,gap:(_==null?void 0:_.gap)??0,fontFamily:(_==null?void 0:_.fontFamily)??Jo[0].value,contrast:(_==null?void 0:_.contrast)??.8,fontSize:O,lineHeight:j}}function $(_){w.value=y(_),o("defaultPreferencesChanged",_)}function k(){if(n.offlineMode){o("pressedBack");return}ff(),o("dispose")}function B(_){const O=Math.floor(_*100)/100;O!==Math.floor(c.value*100)/100&&(c.value=_,!(r>=O)&&(r=O,h(O)))}function A(){n.entryId?o("openEntry",n.entryId):o("addEntry")}function b(_){l.value!==_&&(l.value=_??!l.value)}function g(){o("error"),k()}return(_,O)=>s.value!==void 0?(v(),ie(xs(s.value===X(Kt).novel?Ba:Oa),kn({key:0,ref:"root"},n,{page:X(c),busy:X(u),"chapter-nav-data":d.value,"default-preferences":w.value,onOpenDefaultPreferences:O[1]||(O[1]=()=>o("openDefaultPreferences")),onTimeout:O[2]||(O[2]=()=>o("timeout")),onReady:O[3]||(O[3]=()=>o("ready")),onFinished:O[4]||(O[4]=()=>o("finished")),onPlayingChanged:O[5]||(O[5]=j=>o("playingChanged",j)),onControlsVisibilityChanged:O[6]||(O[6]=j=>o("controlsVisibilityChanged",j)),onPressedBack:O[7]||(O[7]=()=>o("pressedBack")),onGetHiddenChapters:O[8]||(O[8]=()=>o("getHiddenChapters")),onError:g,onHideReader:k,onPageChanged:B,onClickEntryButton:A,onDefaultPreferencesChanged:$,onOpenHelpScreen:O[9]||(O[9]=()=>b(!0))}),{default:oe(()=>[l.value?(v(),ie(Bl,{key:0,"touch-device":e.touchDevice,onHide:b},null,8,["touch-device"])):le("",!0),a.value?(v(),ie(Nl,{key:1,onHide:O[0]||(O[0]=()=>a.value=!1)})):le("",!0)]),_:1},16,["page","busy","chapter-nav-data","default-preferences"])):le("",!0)}}),[["styles",['*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*! tailwindcss v3.4.18 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:Helvetica,sans-serif;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-feature-settings:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]:where(:not([hidden=until-found])){display:none}*{-webkit-tap-highlight-color:rgba(0,0,0,0)!important}button{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-image:none;border-style:none;cursor:pointer;outline:2px solid transparent;outline-offset:2px;white-space:nowrap}button[disabled]{cursor:default!important}svg{height:100%}.container,svg{width:100%}@media (min-width:300px){.container{max-width:300px}}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.scrollbar-none{scrollbar-width:none}.scrollbar-none::-webkit-scrollbar{display:none}.scrollbar-sm{scrollbar-color:#777 transparent;scrollbar-width:thin}.scrollbar-sm::-webkit-scrollbar{background-color:transparent;height:4px;width:4px}.scrollbar-sm::-webkit-scrollbar-track{background:transparent}.scrollbar-sm::-webkit-scrollbar-thumb{background-color:#777;border-radius:2px}.\\!pointer-events-none{pointer-events:none!important}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.\\!visible{visibility:visible!important}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-0{bottom:0}.bottom-1{bottom:4px}.bottom-full{bottom:100%}.left-0{left:0}.left-1{left:4px}.left-1\\/2{left:50%}.left-10{left:40px}.left-3{left:12px}.left-9{left:36px}.right-0{right:0}.top-0{top:0}.top-1{top:4px}.top-1\\/2{top:50%}.top-10{top:40px}.top-2{top:8px}.top-9{top:36px}.top-full{top:100%}.-z-10{z-index:-10}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.order-2{order:2}.m-0{margin:0}.m-auto{margin:auto}.-mx-12{margin-left:-48px;margin-right:-48px}.-my-12{margin-bottom:-48px;margin-top:-48px}.-ml-20{margin-left:-80px}.-mr-3{margin-right:-12px}.-mt-2{margin-top:-8px}.mb-2{margin-bottom:8px}.mb-3{margin-bottom:12px}.mb-5{margin-bottom:20px}.ml-1{margin-left:4px}.ml-auto{margin-left:auto}.mt-5{margin-top:20px}.box-border{box-sizing:border-box}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.hidden{display:none}.\\!h-9{height:36px!important}.h-0{height:0}.h-1{height:4px}.h-1\\/3{height:33.333333%}.h-10{height:40px}.h-12{height:48px}.h-14{height:56px}.h-16{height:64px}.h-2{height:8px}.h-20{height:80px}.h-24{height:96px}.h-28{height:112px}.h-3{height:12px}.h-4{height:16px}.h-5{height:20px}.h-6{height:24px}.h-8{height:32px}.h-9{height:36px}.h-\\[101\\%\\]{height:101%}.h-full{height:100%}.h-screen{height:100vh}.max-h-\\[70vh\\]{max-height:70vh}.max-h-full{max-height:100%}.max-h-none{max-height:none}.min-h-full{min-height:100%}.w-0{width:0}.w-1{width:4px}.w-1\\/3{width:33.333333%}.w-10{width:40px}.w-12{width:48px}.w-14{width:56px}.w-2{width:8px}.w-2\\/3{width:66.666667%}.w-20{width:80px}.w-24{width:96px}.w-28{width:112px}.w-3{width:12px}.w-4{width:16px}.w-40{width:160px}.w-5{width:20px}.w-6{width:24px}.w-auto{width:auto}.w-full{width:100%}.w-min{width:-moz-min-content;width:min-content}.max-w-full{max-width:100%}.max-w-none{max-width:none}.max-w-xs{max-width:320px}.flex-shrink{flex-shrink:1}.flex-shrink-0{flex-shrink:0}.flex-grow{flex-grow:1}.origin-bottom{transform-origin:bottom}.origin-right{transform-origin:right}.origin-top{transform-origin:top}.\\!translate-y-full{--tw-translate-y:100%!important;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-translate-x-1\\/2{--tw-translate-x:-50%}.-translate-x-1\\/2,.-translate-y-1\\.5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\\.5{--tw-translate-y:-6px}.-translate-y-1\\/2{--tw-translate-y:-50%}.-translate-y-1\\/2,.translate-y-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-0{--tw-translate-y:0px}.translate-y-1\\.5{--tw-translate-y:6px}.-rotate-90,.translate-y-1\\.5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rotate-90{--tw-rotate:-90deg}.rotate-180{--tw-rotate:180deg}.rotate-180,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-90{--tw-rotate:90deg}.scale-95{--tw-scale-x:.95;--tw-scale-y:.95}.scale-95,.scale-y-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.scale-y-90{--tw-scale-y:.9}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-auto{cursor:auto}.cursor-default{cursor:default}.cursor-grabbing{cursor:grabbing}.cursor-none{cursor:none}.cursor-pointer{cursor:pointer}.touch-pan-x{--tw-pan-x:pan-x}.touch-pan-x,.touch-pan-y{touch-action:var(--tw-pan-x) var(--tw-pan-y) var(--tw-pinch-zoom)}.touch-pan-y{--tw-pan-y:pan-y}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.select-text{-webkit-user-select:text;-moz-user-select:text;user-select:text}.resize{resize:both}.\\!snap-none{scroll-snap-type:none!important}.snap-x{scroll-snap-type:x var(--tw-scroll-snap-strictness)}.snap-y{scroll-snap-type:y var(--tw-scroll-snap-strictness)}.snap-center{scroll-snap-align:center}.list-none{list-style-type:none}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.flex-row-reverse{flex-direction:row-reverse}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:4px}.gap-2{gap:8px}.gap-3{gap:12px}.gap-4{gap:16px}.gap-6{gap:24px}.gap-\\[1px\\]{gap:1px}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overscroll-contain{overscroll-behavior:contain}.overscroll-none{overscroll-behavior:none}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.rounded{border-radius:4px}.rounded-2xl{border-radius:16px}.rounded-\\[2\\.5rem\\]{border-radius:40px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:8px}.rounded-md{border-radius:6px}.rounded-xl{border-radius:12px}.\\!rounded-l-none{border-bottom-left-radius:0!important;border-top-left-radius:0!important}.\\!rounded-r-none{border-bottom-right-radius:0!important;border-top-right-radius:0!important}.rounded-l-sm{border-bottom-left-radius:2px;border-top-left-radius:2px}.rounded-r-sm{border-bottom-right-radius:2px;border-top-right-radius:2px}.rounded-t-xl{border-top-left-radius:12px;border-top-right-radius:12px}.border{border-width:1px}.border-2{border-width:2px}.border-4{border-width:4px}.border-t-\\[1px\\]{border-top-width:1px}.border-solid{border-style:solid}.border-none{border-style:none}.border-primary{--tw-border-opacity:1;border-color:rgb(184 92 56/var(--tw-border-opacity,1))}.border-stone-200{--tw-border-opacity:1;border-color:rgb(231 229 228/var(--tw-border-opacity,1))}.border-stone-400{--tw-border-opacity:1;border-color:rgb(168 162 158/var(--tw-border-opacity,1))}.border-stone-500{--tw-border-opacity:1;border-color:rgb(120 113 108/var(--tw-border-opacity,1))}.border-stone-600{--tw-border-opacity:1;border-color:rgb(87 83 78/var(--tw-border-opacity,1))}.border-textPrimary{--tw-border-opacity:1;border-color:rgb(251 130 82/var(--tw-border-opacity,1))}.border-opacity-30{--tw-border-opacity:.3}.border-opacity-70{--tw-border-opacity:.7}.bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity,1))}.bg-inherit{background-color:inherit}.bg-primary{--tw-bg-opacity:1;background-color:rgb(184 92 56/var(--tw-bg-opacity,1))}.bg-stone-100{--tw-bg-opacity:1;background-color:rgb(245 245 244/var(--tw-bg-opacity,1))}.bg-stone-300{--tw-bg-opacity:1;background-color:rgb(214 211 209/var(--tw-bg-opacity,1))}.bg-stone-500{--tw-bg-opacity:1;background-color:rgb(120 113 108/var(--tw-bg-opacity,1))}.bg-stone-600{--tw-bg-opacity:1;background-color:rgb(87 83 78/var(--tw-bg-opacity,1))}.bg-stone-800{--tw-bg-opacity:1;background-color:rgb(41 37 36/var(--tw-bg-opacity,1))}.bg-stone-900{--tw-bg-opacity:1;background-color:rgb(28 25 23/var(--tw-bg-opacity,1))}.bg-textPrimary{--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.\\!bg-opacity-100{--tw-bg-opacity:1!important}.bg-opacity-40{--tw-bg-opacity:.4}.bg-opacity-50{--tw-bg-opacity:.5}.bg-opacity-70{--tw-bg-opacity:.7}.bg-opacity-80{--tw-bg-opacity:.8}.bg-opacity-90{--tw-bg-opacity:.9}.bg-none{background-image:none}.object-contain{-o-object-fit:contain;object-fit:contain}.p-0{padding:0}.p-0\\.5{padding:2px}.p-1{padding:4px}.p-2{padding:8px}.p-4{padding:16px}.p-6{padding:24px}.px-2{padding-left:8px;padding-right:8px}.px-3{padding-left:12px;padding-right:12px}.px-4{padding-left:16px;padding-right:16px}.px-5{padding-left:20px;padding-right:20px}.px-6{padding-left:24px;padding-right:24px}.px-8{padding-left:32px;padding-right:32px}.py-0\\.5{padding-bottom:2px;padding-top:2px}.py-1{padding-bottom:4px;padding-top:4px}.py-1\\.5{padding-bottom:6px;padding-top:6px}.py-2{padding-bottom:8px;padding-top:8px}.pb-6{padding-bottom:24px}.pb-7{padding-bottom:28px}.pb-8{padding-bottom:32px}.pl-1{padding-left:4px}.pr-2{padding-right:8px}.pt-1{padding-top:4px}.pt-1\\.5{padding-top:6px}.pt-12{padding-top:48px}.pt-16{padding-top:64px}.pt-20{padding-top:80px}.pt-5{padding-top:20px}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-sans{font-family:Helvetica,sans-serif}.text-base{font-size:16px;line-height:24px}.text-sm{font-size:14px;line-height:20px}.text-xl{font-size:20px;line-height:28px}.font-medium{font-weight:500}.font-normal{font-weight:400}.lowercase{text-transform:lowercase}.leading-none{line-height:1}.text-stone-100{--tw-text-opacity:1;color:rgb(245 245 244/var(--tw-text-opacity,1))}.text-stone-200{--tw-text-opacity:1;color:rgb(231 229 228/var(--tw-text-opacity,1))}.text-stone-300{--tw-text-opacity:1;color:rgb(214 211 209/var(--tw-text-opacity,1))}.text-stone-400{--tw-text-opacity:1;color:rgb(168 162 158/var(--tw-text-opacity,1))}.text-stone-50{--tw-text-opacity:1;color:rgb(250 250 249/var(--tw-text-opacity,1))}.text-stone-800{--tw-text-opacity:1;color:rgb(41 37 36/var(--tw-text-opacity,1))}.text-stone-900{--tw-text-opacity:1;color:rgb(28 25 23/var(--tw-text-opacity,1))}.text-textPrimary{--tw-text-opacity:1;color:rgb(251 130 82/var(--tw-text-opacity,1))}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-90{opacity:.9}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-neutral-950{--tw-shadow-color:#0a0a0a;--tw-shadow:var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-md{--tw-backdrop-blur:blur(12px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-bg{transition-duration:.15s;transition-property:background-color;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-0{transition-duration:0s}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-500{transition-duration:.5s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.children-pointer-events-auto>*{pointer-events:auto}.last\\:mb-0:last-child{margin-bottom:0}.last\\:border-b-transparent:last-child{border-bottom-color:transparent}@media (hover:hover) and (pointer:fine){.hover\\:bg-stone-100:hover{--tw-bg-opacity:1;background-color:rgb(245 245 244/var(--tw-bg-opacity,1))}.hover\\:bg-stone-300:hover{--tw-bg-opacity:1;background-color:rgb(214 211 209/var(--tw-bg-opacity,1))}.hover\\:bg-stone-50:hover{--tw-bg-opacity:1;background-color:rgb(250 250 249/var(--tw-bg-opacity,1))}.hover\\:bg-stone-500:hover{--tw-bg-opacity:1;background-color:rgb(120 113 108/var(--tw-bg-opacity,1))}.hover\\:bg-stone-900:hover{--tw-bg-opacity:1;background-color:rgb(28 25 23/var(--tw-bg-opacity,1))}.hover\\:bg-opacity-10:hover{--tw-bg-opacity:.1}.hover\\:bg-opacity-50:hover{--tw-bg-opacity:.5}.hover\\:bg-opacity-80:hover{--tw-bg-opacity:.8}.hover\\:text-stone-100:hover{--tw-text-opacity:1;color:rgb(245 245 244/var(--tw-text-opacity,1))}}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:outline-primary:focus{outline-color:#b85c38}@media (hover:hover) and (pointer:fine){.group:hover .group-hover\\:bg-stone-100{--tw-bg-opacity:1;background-color:rgb(245 245 244/var(--tw-bg-opacity,1))}.group:hover .group-hover\\:bg-opacity-20{--tw-bg-opacity:.2}}@media (min-width:300px){.\\32xs\\:gap-3{gap:12px}.\\32xs\\:px-3{padding-left:12px;padding-right:12px}}@media (min-width:640px){.sm\\:h-16{height:64px}.sm\\:w-\\[31rem\\]{width:496px}.sm\\:p-3{padding:12px}.sm\\:px-12{padding-left:48px;padding-right:48px}.sm\\:py-3{padding-bottom:12px;padding-top:12px}.sm\\:pt-18{padding-top:72px}.sm\\:pt-9{padding-top:36px}}@media (min-width:768px){.md\\:fixed{position:fixed}.md\\:left-auto{left:auto}.md\\:order-4{order:4}.md\\:inline-block{display:inline-block}.md\\:flex-col{flex-direction:column}.md\\:bg-transparent{background-color:transparent}.md\\:px-14{padding-left:56px;padding-right:56px}.md\\:px-8{padding-left:32px;padding-right:32px}.md\\:pb-5{padding-bottom:20px}.md\\:pb-6{padding-bottom:24px}.md\\:pt-12{padding-top:48px}.md\\:pt-20{padding-top:80px}}@media (min-width:1024px){.lg\\:px-10{padding-left:40px;padding-right:40px}.lg\\:px-16{padding-left:64px;padding-right:64px}.lg\\:pb-3{padding-bottom:12px}.lg\\:pb-4{padding-bottom:16px}}@media (min-width:1280px){.xl\\:px-12{padding-left:48px;padding-right:48px}.xl\\:px-20{padding-left:80px;padding-right:80px}}']]]),Mm=Object.freeze(Object.defineProperty({__proto__:null,default:Va},Symbol.toStringTag,{value:"Module"})),Pm={class:"max-h-none max-w-none h-full w-full m-0 p-0 border-none outline-none"},Em={key:0,class:"fixed inset-0 h-[101%] flex justify-center items-center z-10 bg-black"},Im={class:"flex justify-between items-end"},Om={class:"inline-block children-pointer-events-auto"},$m={class:"inline-flex flex-col items-end gap-4 children-pointer-events-auto"},zm={class:"fixed pointer-events-none left-0 right-0 bottom-0"},Dm={key:1,class:"fixed inline-block left-1/2 -translate-x-1/2 bottom-0 p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3"},Am=Object.freeze(Object.defineProperty({__proto__:null,default:be(ge({__name:"ReaderLayout",props:{loading:{type:Boolean},immediate:{type:Boolean},idle:{type:Boolean},controlsVisible:{type:Boolean},zooming:{type:Boolean},spaceTop:{type:null}},setup(e,{expose:t}){const n={mounted:i=>i.showModal(),beforeUnmount:i=>i.close()},o=te(null);return t({rootEl:o}),(i,r)=>Re((v(),z("dialog",Pm,[Y("div",{ref_key:"rootEl",ref:o,id:"reader-layout",class:ue({"cursor-none":e.idle,"cursor-default":!e.idle,"bg-black":e.immediate||!e.loading,"opacity-0":!e.immediate&&e.loading,"duration-200 transition-colors":!e.immediate})},[e.loading&&e.immediate?(v(),z("div",Em,[V(oi)])):le("",!0),Se(i.$slots,"default"),Y("div",{id:"controls",class:ue(["fixed pointer-events-none cursor-auto left-0 top-0 w-full h-full flex flex-col justify-between p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3",{"opacity-100 z-20":e.controlsVisible,"opacity-0 -z-10":!e.controlsVisible}])},[Y("div",{class:"flex gap-1 items-center children-pointer-events-auto relative z-30 flex-shrink-0 2xs:gap-3",style:Ce({paddingTop:`${e.spaceTop||0}px`})},[Se(i.$slots,"top-controls")],4),Y("div",Im,[Y("div",Om,[Se(i.$slots,"bottom-left-controls")]),Y("div",$m,[Se(i.$slots,"bottom-right-controls")])]),Y("div",zm,[Se(i.$slots,"progress")])],2),e.controlsVisible||e.zooming?(v(),z("div",Dm,[Se(i.$slots,"reset-zoom")])):le("",!0)],2)])),[[n]])}}),[["styles",["#reader-layout{direction:ltr;font-family:Helvetica,sans-serif;font-size:16px;font-weight:400;height:100%;line-height:24px;overflow:hidden;overscroll-behavior:contain;pointer-events:auto;text-align:left;width:100%;--tw-text-opacity:1;color:rgb(245 245 244/var(--tw-text-opacity,1))}"]]])},Symbol.toStringTag,{value:"Module"})),Lm={},jm={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function Bm(e,t){return v(),z("svg",jm,[...t[0]||(t[0]=[Y("path",{fill:"currentColor",d:"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46s46-20.595 46-46s-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1)])])}const Nm=Object.freeze(Object.defineProperty({__proto__:null,default:be(Lm,[["render",Bm]])},Symbol.toStringTag,{value:"Module"})),Vm="gear-second{height:0!important;opacity:0!important;pointer-events:none!important;width:0!important;z-index:-10!important}html.gear-second,html.gear-second *{scroll-behavior:auto!important;scrollbar-width:none!important}html.gear-second ::-webkit-scrollbar,html.gear-second::-webkit-scrollbar{display:none!important}html.gear-second body{touch-action:pan-x pan-y!important}html.gear-second body .m-content #progress-bar{display:none!important}html.gear-second body>:not(dialog[open]),html.gear-second>body~*{visibility:hidden!important}html.gear-second>body~*{display:none!important;height:0!important;left:100%!important;max-height:0!important;max-width:0!important;opacity:0!important;pointer-events:none!important;top:100%!important;width:0!important}.mp-scroll-container{max-height:100vh!important;overflow:hidden!important}html:has(body.mp-scroll-container){overflow:auto!important}",on="gear-second",kr={appVersion:void 0,immediate:void 0,raw:void 0,spec:void 0,siteMeta:void 0,page:0,spaceTop:void 0,touchDevice:void 0,entryId:void 0,isAutoShow:void 0,tourEnabled:void 0,offlineMode:void 0,defaultPreferences:void 0,onError:void 0,onCrash:void 0,onDispose:void 0,onFullScreenChanged:void 0,onControlsVisibilityChanged:void 0,onPageChanged:void 0,onOpenEntry:void 0,onAddEntry:void 0,onFinished:void 0,onHapticFeedback:void 0,onPressedBack:void 0,onSelectChapter:void 0,onTimeout:void 0,onDefaultPreferencesChanged:void 0,onOpenDefaultPreferences:void 0},St={promise:void 0,data:xo({...kr})};async function Rm(e){let t=!1,n=!1,o,i,r,s;const l=!!e.spaceTop||!!e.isAutoShow&&!!e.page,a=()=>{t||(t=!0,clearInterval(o),o=void 0,i!=null&&i.isConnected&&document.body.removeChild(i),document.documentElement.classList.remove(on),St.data.touchDevice||Object.assign(St.data,kr),St.promise=void 0,to.clear())};if(Object.assign(St.data,kr,e.appVersion?e:Ra(e),{immediate:l,onReady(){l||(r==null||r(),document.documentElement.classList.add(on))},onError(){var c,d;a(),n?((c=e.onDispose)==null||c.call(e),(d=e.onError)==null||d.call(e)):s==null||s()},onDispose:()=>{var c;a(),(c=e==null?void 0:e.onDispose)==null||c.call(e)},onControlsVisibilityChanged(c){var d,f;(d=e.onFullScreenChanged)==null||d.call(e,!c),(f=e.onControlsVisibilityChanged)==null||f.call(e,c)}}),St.promise)return await St.promise;const u=c=>{Object.assign(St.data,St.data.appVersion?c:Ra(c))};return St.promise=new Promise(c=>{r=()=>{n||(n=!0,c({updateArgs:u,dispose:a,back:()=>to.trigger()}))},s=()=>{n||c(void 0)},Hm().then(()=>{if(t){s==null||s();return}i=document.createElement(on),l?(document.documentElement.classList.add(on),document.body.appendChild(i),setTimeout(()=>r==null?void 0:r())):document.body.appendChild(i);let d=0;o=setInterval(()=>{if(++d===30||t){clearInterval(o),o=void 0;return}i.isConnected||(document.documentElement.classList.add(on),document.body.appendChild(i))},100)})}),await St.promise}function Ra(e){if(!["autoPlay","readerStyle","direction","autoNextSeconds","defaultSpeed","defaultGap","hideControlsEvent","progressSize","pinchToZoom","tapZone"].some(h=>h in e))return e;const{autoPlay:n,readerStyle:o,direction:i,autoNextSeconds:r,defaultSpeed:s,defaultGap:l,hideControlsEvent:a,progressSize:u,pinchToZoom:c,tapZone:d,...f}=e;return{...f,defaultPreferences:{autoPlay:n,readerStyle:o,direction:i,autoNextSeconds:r,speed:s,gap:l,hideControlsEvent:a,progressSize:u,pinchToZoom:c,tapZone:d}}}async function Hm(){if(window.customElements.get(on))return;const e=await Fm();if(window.customElements.get(on))return;const t=document.createElement("style"),n=Vm;t.appendChild(document.createTextNode(n)),document.head.appendChild(t);const o=md({styles:[e],data:()=>({readerData:St.data}),render(){return il(Va,this.readerData)}});window.customElements.define(on,o)}async function Fm(){const e=Object.assign({"./App.vue":Mm,"./GearSecond.vue":im,"./GearThird.vue":Sm,"./components/AutoNext.vue":Cf,"./components/ButtonWebFullScreen.vue":xp,"./components/ChapterNav.vue":qp,"./components/DefaultPreferencesForm.vue":Ph,"./components/DirectionToast.vue":Ah,"./components/GearControlsLayout.vue":Bh,"./components/GearLayout.vue":qh,"./components/GearThirdControlsLayout.vue":pm,"./components/GesturesContainer.vue":lg,"./components/HelpScreen.vue":nf,"./components/MangaPreferencesForm.vue":ng,"./components/NovelBody.vue":_m,"./components/NovelPreferencesForm.vue":Sh,"./components/PageNav.vue":og,"./components/PauseToast.vue":ig,"./components/ProgressBar.vue":sg,"./components/ReaderBody.vue":pg,"./components/ReaderImg.vue":cg,"./components/ReaderLayout.vue":Am,"./components/ReaderTour.vue":sf,"./components/SettingsBottomSheet.vue":zg,"./components/TapZonePreview.vue":zh,"./components/base/BaseButton.vue":gf,"./components/base/BottomSheet.vue":yg,"./components/base/ButtonDropdown.vue":Lp,"./components/base/ButtonIcon.vue":Tf,"./components/base/ButtonOutline.vue":hh,"./components/base/DropdownMenu.vue":kp,"./components/base/InputPercentage.vue":Yp,"./components/base/InputSelect.vue":Jp,"./components/base/InputSwitcher.vue":nh,"./components/base/LoadingIndicator.vue":Fh,"./components/base/TabBar.vue":xg,"./components/base/TableField.vue":ih,"./components/buttons/ButtonBack.vue":Of,"./components/buttons/ButtonEntry.vue":Vf,"./components/buttons/ButtonHide.vue":Uf,"./components/buttons/ButtonPlay.vue":ep,"./components/buttons/ButtonResetZoom.vue":lp,"./components/buttons/ButtonSettings.vue":fp,"./components/fields/FieldContrast.vue":rh,"./components/fields/FieldFontFamily.vue":gh,"./components/icons/IconBack.vue":If,"./components/icons/IconBookmarkNew.vue":Nf,"./components/icons/IconBookmarked.vue":Af,"./components/icons/IconChevronLeft.vue":Vp,"./components/icons/IconChevronRight.vue":Wp,"./components/icons/IconClose.vue":vg,"./components/icons/IconDouble.vue":Xh,"./components/icons/IconDoubleSkip.vue":eg,"./components/icons/IconExclamationCircle.vue":Nm,"./components/icons/IconFullscreen.vue":mp,"./components/icons/IconFullscreenExit.vue":wp,"./components/icons/IconHelp.vue":Cg,"./components/icons/IconLandscape.vue":ch,"./components/icons/IconLoading.vue":Pp,"./components/icons/IconMoreVert.vue":Eg,"./components/icons/IconNext.vue":$h,"./components/icons/IconPause.vue":Yf,"./components/icons/IconPlay.vue":Qf,"./components/icons/IconPlus.vue":yf,"./components/icons/IconPortrait.vue":ph,"./components/icons/IconReaderExit.vue":Wf,"./components/icons/IconSettings.vue":dp,"./components/icons/IconTextDecre.vue":vm,"./components/icons/IconTextIncre.vue":xm,"./components/icons/IconTriangle.vue":$p,"./components/icons/IconZoom.vue":ip}),t=[];for(const n in e){const o=e[n];t.push(o.default.styles)}return t.join("")}return Rm});
|
|
20
|
+
**/let Hi;const dl=typeof window<"u"&&window.trustedTypes;if(dl)try{Hi=dl.createPolicy("vue",{createHTML:e=>e})}catch{}const fl=Hi?e=>Hi.createHTML(e):e=>e,sd="http://www.w3.org/2000/svg",ld="http://www.w3.org/1998/Math/MathML",Ut=typeof document<"u"?document:null,pl=Ut&&Ut.createElement("template"),ad={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const i=t==="svg"?Ut.createElementNS(sd,e):t==="mathml"?Ut.createElementNS(ld,e):n?Ut.createElement(e,{is:n}):Ut.createElement(e);return e==="select"&&o&&o.multiple!=null&&i.setAttribute("multiple",o.multiple),i},createText:e=>Ut.createTextNode(e),createComment:e=>Ut.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ut.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,o,i,r){const s=n?n.previousSibling:t.lastChild;if(i&&(i===r||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===r||!(i=i.nextSibling)););else{pl.innerHTML=fl(o==="svg"?`<svg>${e}</svg>`:o==="mathml"?`<math>${e}</math>`:e);const l=pl.content;if(o==="svg"||o==="mathml"){const a=l.firstChild;for(;a.firstChild;)l.appendChild(a.firstChild);l.removeChild(a)}t.insertBefore(l,n)}return[s?s.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},en="transition",Qn="animation",eo=Symbol("_vtc"),hl={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},cd=$e({},ms,hl),to=(e=>(e.displayName="Transition",e.props=cd,e))((e,{slots:t})=>ul(iu,ud(e),t)),pn=(e,t=[])=>{le(e)?e.forEach(n=>n(...t)):e&&e(...t)},gl=e=>e?le(e)?e.some(t=>t.length>1):e.length>1:!1;function ud(e){const t={};for(const A in e)A in hl||(t[A]=e[A]);if(e.css===!1)return t;const{name:n="v",type:o,duration:i,enterFromClass:r=`${n}-enter-from`,enterActiveClass:s=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:a=r,appearActiveClass:u=s,appearToClass:c=l,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=e,b=dd(i),y=b&&b[0],$=b&&b[1],{onBeforeEnter:k,onEnter:B,onEnterCancelled:F,onLeave:C,onLeaveCancelled:g,onBeforeAppear:T=k,onAppear:x=B,onAppearCancelled:z=F}=t,w=(A,X,I,ne)=>{A._enterCancelled=ne,hn(A,X?c:l),hn(A,X?u:s),I&&I()},M=(A,X)=>{A._isLeaving=!1,hn(A,d),hn(A,p),hn(A,f),X&&X()},W=A=>(X,I)=>{const ne=A?x:B,G=()=>w(X,A,I);pn(ne,[X,G]),ml(()=>{hn(X,A?a:r),Kt(X,A?c:l),gl(ne)||vl(X,o,y,G)})};return $e(t,{onBeforeEnter(A){pn(k,[A]),Kt(A,r),Kt(A,s)},onBeforeAppear(A){pn(T,[A]),Kt(A,a),Kt(A,u)},onEnter:W(!1),onAppear:W(!0),onLeave(A,X){A._isLeaving=!0;const I=()=>M(A,X);Kt(A,d),A._enterCancelled?(Kt(A,f),wl(A)):(wl(A),Kt(A,f)),ml(()=>{A._isLeaving&&(hn(A,d),Kt(A,p),gl(C)||vl(A,o,$,I))}),pn(C,[A,I])},onEnterCancelled(A){w(A,!1,void 0,!0),pn(F,[A])},onAppearCancelled(A){w(A,!0,void 0,!0),pn(z,[A])},onLeaveCancelled(A){M(A),pn(g,[A])}})}function dd(e){if(e==null)return null;if(Ie(e))return[Fi(e.enter),Fi(e.leave)];{const t=Fi(e);return[t,t]}}function Fi(e){return pi(e)}function Kt(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[eo]||(e[eo]=new Set)).add(t)}function hn(e,t){t.split(/\s+/).forEach(o=>o&&e.classList.remove(o));const n=e[eo];n&&(n.delete(t),n.size||(e[eo]=void 0))}function ml(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let fd=0;function vl(e,t,n,o){const i=e._endId=++fd,r=()=>{i===e._endId&&o()};if(n!=null)return setTimeout(r,n);const{type:s,timeout:l,propCount:a}=pd(e,t);if(!s)return o();const u=s+"end";let c=0;const d=()=>{e.removeEventListener(u,f),r()},f=p=>{p.target===e&&++c>=a&&d()};setTimeout(()=>{c<a&&d()},l+1),e.addEventListener(u,f)}function pd(e,t){const n=window.getComputedStyle(e),o=b=>(n[b]||"").split(", "),i=o(`${en}Delay`),r=o(`${en}Duration`),s=bl(i,r),l=o(`${Qn}Delay`),a=o(`${Qn}Duration`),u=bl(l,a);let c=null,d=0,f=0;t===en?s>0&&(c=en,d=s,f=r.length):t===Qn?u>0&&(c=Qn,d=u,f=a.length):(d=Math.max(s,u),c=d>0?s>u?en:Qn:null,f=c?c===en?r.length:a.length:0);const p=c===en&&/\b(?:transform|all)(?:,|$)/.test(o(`${en}Property`).toString());return{type:c,timeout:d,propCount:f,hasTransform:p}}function bl(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,o)=>yl(n)+yl(e[o])))}function yl(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function wl(e){return(e?e.ownerDocument:document).body.offsetHeight}function hd(e,t,n){const o=e[eo];o&&(t=(t?[t,...o]:[...o]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Wo=Symbol("_vod"),xl=Symbol("_vsh"),gd={name:"show",beforeMount(e,{value:t},{transition:n}){e[Wo]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):no(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),no(e,!0),o.enter(e)):o.leave(e,()=>{no(e,!1)}):no(e,t))},beforeUnmount(e,{value:t}){no(e,t)}};function no(e,t){e.style.display=t?e[Wo]:"none",e[xl]=!t}const md=Symbol(""),vd=/(?:^|;)\s*display\s*:/;function bd(e,t,n){const o=e.style,i=De(n);let r=!1;if(n&&!i){if(t)if(De(t))for(const s of t.split(";")){const l=s.slice(0,s.indexOf(":")).trim();n[l]==null&&qo(o,l,"")}else for(const s in t)n[s]==null&&qo(o,s,"");for(const s in n)s==="display"&&(r=!0),qo(o,s,n[s])}else if(i){if(t!==n){const s=o[md];s&&(n+=";"+s),o.cssText=n,r=vd.test(n)}}else t&&e.removeAttribute("style");Wo in e&&(e[Wo]=r?o.display:"",e[xl]&&(o.display="none"))}const _l=/\s*!important$/;function qo(e,t,n){if(le(n))n.forEach(o=>qo(e,t,o));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const o=yd(e,t);_l.test(n)?e.setProperty(et(o),n.replace(_l,""),"important"):e[o]=n}}const Sl=["Webkit","Moz","ms"],Wi={};function yd(e,t){const n=Wi[t];if(n)return n;let o=Fe(t);if(o!=="filter"&&o in e)return Wi[t]=o;o=fo(o);for(let i=0;i<Sl.length;i++){const r=Sl[i]+o;if(r in e)return Wi[t]=r}return t}const kl="http://www.w3.org/1999/xlink";function Cl(e,t,n,o,i,r=fc(t)){o&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(kl,t.slice(6,t.length)):e.setAttributeNS(kl,t,n):n==null||r&&!Lr(n)?e.removeAttribute(t):e.setAttribute(t,r?"":yt(n)?String(n):n)}function Tl(e,t,n,o,i){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?fl(n):n);return}const r=e.tagName;if(t==="value"&&r!=="PROGRESS"&&!r.includes("-")){const l=r==="OPTION"?e.getAttribute("value")||"":e.value,a=n==null?e.type==="checkbox"?"on":"":String(n);(l!==a||!("_value"in e))&&(e.value=a),n==null&&e.removeAttribute(t),e._value=n;return}let s=!1;if(n===""||n==null){const l=typeof e[t];l==="boolean"?n=Lr(n):n==null&&l==="string"?(n="",s=!0):l==="number"&&(n=0,s=!0)}try{e[t]=n}catch{}s&&e.removeAttribute(i||t)}function gn(e,t,n,o){e.addEventListener(t,n,o)}function wd(e,t,n,o){e.removeEventListener(t,n,o)}const Pl=Symbol("_vei");function xd(e,t,n,o,i=null){const r=e[Pl]||(e[Pl]={}),s=r[t];if(o&&s)s.value=o;else{const[l,a]=_d(t);if(o){const u=r[t]=Cd(o,i);gn(e,l,u,a)}else s&&(wd(e,l,s,a),r[t]=void 0)}}const Il=/(?:Once|Passive|Capture)$/;function _d(e){let t;if(Il.test(e)){t={};let o;for(;o=e.match(Il);)e=e.slice(0,e.length-o[0].length),t[o[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):et(e.slice(2)),t]}let qi=0;const Sd=Promise.resolve(),kd=()=>qi||(Sd.then(()=>qi=0),qi=Date.now());function Cd(e,t){const n=o=>{if(!o._vts)o._vts=Date.now();else if(o._vts<=n.attached)return;xt(Td(o,n.value),t,5,[o])};return n.value=e,n.attached=kd(),n}function Td(e,t){if(le(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(o=>i=>!i._stopped&&o&&o(i))}else return t}const El=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Pd=(e,t,n,o,i,r)=>{const s=i==="svg";t==="class"?hd(e,o,s):t==="style"?bd(e,n,o):lo(t)?ai(t)||xd(e,t,n,o,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Id(e,t,o,s))?(Tl(e,t,o),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Cl(e,t,o,s,r,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!De(o))?Tl(e,Fe(t),o,r,t):(t==="true-value"?e._trueValue=o:t==="false-value"&&(e._falseValue=o),Cl(e,t,o,s))};function Id(e,t,n,o){if(o)return!!(t==="innerHTML"||t==="textContent"||t in e&&El(t)&&he(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 i=e.tagName;if(i==="IMG"||i==="VIDEO"||i==="CANVAS"||i==="SOURCE")return!1}return El(t)&&De(n)?!1:t in e}const Ml={};function Ed(e,t,n){let o=ge(e,t);co(o)&&(o=$e({},o,t));class i extends Ui{constructor(s){super(o,s,n)}}return i.def=o,i}const Md=typeof HTMLElement<"u"?HTMLElement:class{};class Ui extends Md{constructor(t,n={},o=Ll){super(),this._def=t,this._props=n,this._createApp=o,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._patching=!1,this._dirty=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&o!==Ll?this._root=this.shadowRoot:t.shadowRoot!==!1?(this.attachShadow($e({},t.shadowRootOptions,{mode:"open"})),this._root=this.shadowRoot):this._root=this}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let t=this;for(;t=t&&(t.parentNode||t.host);)if(t instanceof Ui){this._parent=t;break}this._instance||(this._resolved?this._mount(this._def):t&&t._pendingResolve?this._pendingResolve=t._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(t=this._parent){t&&(this._instance.parent=t._instance,this._inheritParentContext(t))}_inheritParentContext(t=this._parent){t&&this._app&&Object.setPrototypeOf(this._app._context.provides,t._instance.provides)}disconnectedCallback(){this._connected=!1,pt(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&(this._teleportTargets.clear(),this._teleportTargets=void 0))})}_processMutations(t){for(const n of t)this._setAttr(n.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let o=0;o<this.attributes.length;o++)this._setAttr(this.attributes[o].name);this._ob=new MutationObserver(this._processMutations.bind(this)),this._ob.observe(this,{attributes:!0});const t=(o,i=!1)=>{this._resolved=!0,this._pendingResolve=void 0;const{props:r,styles:s}=o;let l;if(r&&!le(r))for(const a in r){const u=r[a];(u===Number||u&&u.type===Number)&&(a in this._props&&(this._props[a]=pi(this._props[a])),(l||(l=Object.create(null)))[Fe(a)]=!0)}this._numberProps=l,this._resolveProps(o),this.shadowRoot&&this._applyStyles(s),this._mount(o)},n=this._def.__asyncLoader;n?this._pendingResolve=n().then(o=>{o.configureApp=this._def.configureApp,t(this._def=o,!0)}):t(this._def)}_mount(t){this._app=this._createApp(t),this._inheritParentContext(),t.configureApp&&t.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);const n=this._instance&&this._instance.exposed;if(n)for(const o in n)Ce(this,o)||Object.defineProperty(this,o,{get:()=>Z(n[o])})}_resolveProps(t){const{props:n}=t,o=le(n)?n:Object.keys(n||{});for(const i of Object.keys(this))i[0]!=="_"&&o.includes(i)&&this._setProp(i,this[i]);for(const i of o.map(Fe))Object.defineProperty(this,i,{get(){return this._getProp(i)},set(r){this._setProp(i,r,!0,!this._patching)}})}_setAttr(t){if(t.startsWith("data-v-"))return;const n=this.hasAttribute(t);let o=n?this.getAttribute(t):Ml;const i=Fe(t);n&&this._numberProps&&this._numberProps[i]&&(o=pi(o)),this._setProp(i,o,!1,!0)}_getProp(t){return this._props[t]}_setProp(t,n,o=!0,i=!1){if(n!==this._props[t]&&(this._dirty=!0,n===Ml?delete this._props[t]:(this._props[t]=n,t==="key"&&this._app&&(this._app._ceVNode.key=n)),i&&this._instance&&this._update(),o)){const r=this._ob;r&&(this._processMutations(r.takeRecords()),r.disconnect()),n===!0?this.setAttribute(et(t),""):typeof n=="string"||typeof n=="number"?this.setAttribute(et(t),n+""):n||this.removeAttribute(et(t)),r&&r.observe(this,{attributes:!0})}}_update(){const t=this._createVNode();this._app&&(t.appContext=this._app._context),Nd(t,this._root)}_createVNode(){const t={};this.shadowRoot||(t.onVnodeMounted=t.onVnodeUpdated=this._renderSlots.bind(this));const n=j(this._def,$e(t,this._props));return this._instance||(n.ce=o=>{this._instance=o,o.ce=this,o.isCE=!0;const i=(r,s)=>{this.dispatchEvent(new CustomEvent(r,co(s[0])?$e({detail:s},s[0]):{detail:s}))};o.emit=(r,...s)=>{i(r,s),et(r)!==r&&i(et(r),s)},this._setParent()}),n}_applyStyles(t,n){if(!t)return;if(n){if(n===this._def||this._styleChildren.has(n))return;this._styleChildren.add(n)}const o=this._nonce;for(let i=t.length-1;i>=0;i--){const r=document.createElement("style");o&&r.setAttribute("nonce",o),r.textContent=t[i],this.shadowRoot.prepend(r)}}_parseSlots(){const t=this._slots={};let n;for(;n=this.firstChild;){const o=n.nodeType===1&&n.getAttribute("slot")||"default";(t[o]||(t[o]=[])).push(n),this.removeChild(n)}}_renderSlots(){const t=this._getSlots(),n=this._instance.type.__scopeId;for(let o=0;o<t.length;o++){const i=t[o],r=i.getAttribute("name")||"default",s=this._slots[r],l=i.parentNode;if(s)for(const a of s){if(n&&a.nodeType===1){const u=n+"-s",c=document.createTreeWalker(a,1);a.setAttribute(u,"");let d;for(;d=c.nextNode();)d.setAttribute(u,"")}l.insertBefore(a,i)}else for(;i.firstChild;)l.insertBefore(i.firstChild,i);l.removeChild(i)}}_getSlots(){const t=[this];this._teleportTargets&&t.push(...this._teleportTargets);const n=new Set;for(const o of t){const i=o.querySelectorAll("slot");for(let r=0;r<i.length;r++)n.add(i[r])}return Array.from(n)}_injectChildStyle(t){this._applyStyles(t.styles,t)}_beginPatch(){this._patching=!0,this._dirty=!1}_endPatch(){this._patching=!1,this._dirty&&this._instance&&this._update()}_removeChildStyle(t){}}const Uo=e=>{const t=e.props["onUpdate:modelValue"]||!1;return le(t)?n=>po(t,n):t};function Od(e){e.target.composing=!0}function Ol(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const En=Symbol("_assign");function $l(e,t,n){return t&&(e=e.trim()),n&&(e=fi(e)),e}const $d={created(e,{modifiers:{lazy:t,trim:n,number:o}},i){e[En]=Uo(i);const r=o||i.props&&i.props.type==="number";gn(e,t?"change":"input",s=>{s.target.composing||e[En]($l(e.value,n,r))}),(n||r)&&gn(e,"change",()=>{e.value=$l(e.value,n,r)}),t||(gn(e,"compositionstart",Od),gn(e,"compositionend",Ol),gn(e,"change",Ol))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:o,trim:i,number:r}},s){if(e[En]=Uo(s),e.composing)return;const l=(r||e.type==="number")&&!/^0\d/.test(e.value)?fi(e.value):e.value,a=t??"";l!==a&&(document.activeElement===e&&e.type!=="range"&&(o&&t===n||i&&e.value.trim()===a)||(e.value=a))}},Dd={deep:!0,created(e,t,n){e[En]=Uo(n),gn(e,"change",()=>{const o=e._modelValue,i=zd(e),r=e.checked,s=e[En];if(le(o)){const l=jr(o,i),a=l!==-1;if(r&&!a)s(o.concat(i));else if(!r&&a){const u=[...o];u.splice(l,1),s(u)}}else if(ao(o)){const l=new Set(o);r?l.add(i):l.delete(i),s(l)}else s(zl(e,r))})},mounted:Dl,beforeUpdate(e,t,n){e[En]=Uo(n),Dl(e,t,n)}};function Dl(e,{value:t,oldValue:n},o){e._modelValue=t;let i;if(le(t))i=jr(t,o.props.value)>-1;else if(ao(t))i=t.has(o.props.value);else{if(t===n)return;i=go(t,zl(e,!0))}e.checked!==i&&(e.checked=i)}function zd(e){return"_value"in e?e._value:e.value}function zl(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Ad=["ctrl","shift","alt","meta"],Bd={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)=>Ad.some(n=>e[`${n}Key`]&&!t.includes(n))},Ne=(e,t)=>{const n=e._withMods||(e._withMods={}),o=t.join(".");return n[o]||(n[o]=(i,...r)=>{for(let s=0;s<t.length;s++){const l=Bd[t[s]];if(l&&l(i,t))return}return e(i,...r)})},Ld={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Ko=(e,t)=>{const n=e._withKeys||(e._withKeys={}),o=t.join(".");return n[o]||(n[o]=i=>{if(!("key"in i))return;const r=et(i.key);if(t.some(s=>s===r||Ld[s]===r))return e(i)})},jd=$e({patchProp:Pd},ad);let Al;function Bl(){return Al||(Al=Mu(jd))}const Nd=(...e)=>{Bl().render(...e)},Ll=(...e)=>{const t=Bl().createApp(...e),{mount:n}=t;return t.mount=o=>{const i=Rd(o);if(!i)return;const r=t._component;!he(r)&&!r.render&&!r.template&&(r.template=i.innerHTML),i.nodeType===1&&(i.textContent="");const s=n(i,!1,Vd(i));return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),s},t};function Vd(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Rd(e){return De(e)?document.querySelector(e):e}function Mn(e,t){if(typeof e.checkVisibility=="function")return e.checkVisibility({opacityProperty:!0,visibilityProperty:!1,contentVisibilityAuto:!1});const n=window.getComputedStyle(e);if(n.display==="none"||n.opacity&&parseFloat(n.opacity)<.1)return!1;if(!t)return!0;const o=e.parentElement;return!o||o===t?!0:Mn(o,t)}async function gt(e,t,n){const o=await n(()=>{e=0});if(o!==void 0)return o;if(!(e<=0))return await new Promise(i=>{setTimeout(async()=>{const r=await gt(e-1,t,n);i(r)},t)})}function mn(e,t){return e>=280&&t>=50||e>=160&&t>=280}var Zt;(function(e){e[e.manga=1]="manga",e[e.novel=2]="novel",e[e.anime=3]="anime"})(Zt||(Zt={}));async function Hd(e,t){const n=["NAV","ASIDE","FOOTER","HEADER","BR","HR","BUTTON","A"],o="img:not(nav img, header img, footer img, aside img), canvas",i=t==null?void 0:t.timeoutMs,r=t==null?void 0:t.include,s=t==null?void 0:t.paraSel,l=!r||r.includes(Zt.manga),a=!r||r.includes(Zt.novel);let u=0;return await gt(i/50,50,()=>{const p=c();if(p){if(l&&f(p,t==null?void 0:t.validateImgSize))return Zt.manga;if(a&&u++%3===0&&d(p))return Zt.novel}});function c(){for(const p of e.split(",")){const b=document.querySelector(p);if(b)return b}}function d(p){const b=[`p:not(${n.map(F=>`${F} p`).join(",")})`,s].filter(Boolean).join(",");if(!p.querySelector(b)&&(!s||!p.matches(s)))return!1;let y=0,$=0,k=0;return B(p);function B(F){const C=F.tagName;if(n.includes(C)||!Mn(F)||window.getComputedStyle(F).position==="fixed")return!1;if(C==="P"||s&&F.matches(s))return y+=F.textContent.split(" ").filter(Boolean).length,$++,k=0,!l&&y>50||$>10&&y>120||$>5&&y>250||y>400;$>0&&++k>4&&($=0,y=0);const T=Array.from(F.children);for(let x=0;x<T.length;x++)if(B(T[x]))return!0;return!1}}function f(p,b){const y=Array.from(p.querySelectorAll(o));if(b===!1)return y.length>0;const $=Math.min(window.innerWidth*.9,500);let k=0;for(let B=0;B<y.length;B++){const F=y[B];if(!Mn(F,p))continue;const{width:C,height:g}=F.getBoundingClientRect();if(mn(C,g)&&(C>=$||(k+=g,k>=$)))return!0}return!1}}function Ki(e,t){return gi()?(gc(e,t),!0):!1}const Zi=new WeakMap,Fd=(...e)=>{var t;const n=e[0],o=(t=fn())===null||t===void 0?void 0:t.proxy,i=o??gi();if(i==null&&!Bs())throw new Error("injectLocal must be called in setup");return i&&Zi.has(i)&&n in Zi.get(i)?Zi.get(i)[n]:Wt(...e)},jl=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Wd=e=>e!=null,qd=Object.prototype.toString,Ud=e=>qd.call(e)==="[object Object]",On=()=>{};function Kd(...e){if(e.length!==1)return Hc(...e);const t=e[0];return typeof t=="function"?Vn(ls(()=>({get:t,set:On}))):ee(t)}function Nl(e,t){function n(...o){return new Promise((i,r)=>{Promise.resolve(e(()=>t.apply(this,o),{fn:t,thisArg:this,args:o})).then(i).catch(r)})}return n}const Vl=e=>e();function Zd(e,t={}){let n,o,i=On;const r=a=>{clearTimeout(a),i(),i=On};let s;return a=>{const u=ft(e),c=ft(t.maxWait);return n&&r(n),u<=0||c!==void 0&&c<=0?(o&&(r(o),o=void 0),Promise.resolve(a())):new Promise((d,f)=>{i=t.rejectOnCancel?f:d,s=a,c&&!o&&(o=setTimeout(()=>{n&&r(n),o=void 0,d(s())},c)),n=setTimeout(()=>{o&&r(o),o=void 0,d(a())},u)})}}function Yd(e=Vl,t={}){const{initialState:n="active"}=t,o=Kd(n==="active");function i(){o.value=!1}function r(){o.value=!0}const s=(...l)=>{o.value&&e(...l)};return{isActive:Vn(o),pause:i,resume:r,eventFilter:s}}function Rl(e){return e.endsWith("rem")?Number.parseFloat(e)*16:Number.parseFloat(e)}function oo(e){return Array.isArray(e)?e:[e]}function Xd(e){return fn()}function mt(e,t=200,n={}){return Nl(Zd(t,n),e)}function Gd(e,t,n={}){const{eventFilter:o=Vl,...i}=n;return fe(e,Nl(o,t),i)}function Jd(e,t,n={}){const{eventFilter:o,initialState:i="active",...r}=n,{eventFilter:s,pause:l,resume:a,isActive:u}=Yd(o,{initialState:i});return{stop:Gd(e,t,{...r,eventFilter:s}),pause:l,resume:a,isActive:u}}const Qd=Jd;function Yi(e,t=!0,n){Xd()?je(e,n):t?e():pt(e)}function ef(e,t,n){return fe(e,t,{...n,immediate:!0})}const _t=jl?window:void 0,tf=jl?window.document:void 0;function $t(e){var t;const n=ft(e);return(t=n==null?void 0:n.$el)!==null&&t!==void 0?t:n}function St(...e){const t=[],n=()=>{t.forEach(l=>l()),t.length=0},o=(l,a,u,c)=>(l.addEventListener(a,u,c),()=>l.removeEventListener(a,u,c)),i=Q(()=>{const l=oo(ft(e[0])).filter(a=>a!=null);return l.every(a=>typeof a!="string")?l:void 0}),r=ef(()=>{var l,a;return[(l=(a=i.value)===null||a===void 0?void 0:a.map(u=>$t(u)))!==null&&l!==void 0?l:[_t].filter(u=>u!=null),oo(ft(i.value?e[1]:e[0])),oo(Z(i.value?e[2]:e[1])),ft(i.value?e[3]:e[2])]},([l,a,u,c])=>{if(n(),!(l!=null&&l.length)||!(a!=null&&a.length)||!(u!=null&&u.length))return;const d=Ud(c)?{...c}:c;t.push(...l.flatMap(f=>a.flatMap(p=>u.map(b=>o(f,p,b,d)))))},{flush:"post"}),s=()=>{r(),n()};return Ki(n),s}function nf(){const e=dt(!1),t=fn();return t&&je(()=>{e.value=!0},t),e}function Xi(e){const t=nf();return Q(()=>(t.value,!!e()))}const of=Symbol("vueuse-ssr-width");function rf(){const e=Bs()?Fd(of,null):null;return typeof e=="number"?e:void 0}function sf(e,t={}){const{window:n=_t,ssrWidth:o=rf()}=t,i=Xi(()=>n&&"matchMedia"in n&&typeof n.matchMedia=="function"),r=dt(typeof o=="number"),s=dt(),l=dt(!1),a=u=>{l.value=u.matches};return Ys(()=>{if(r.value){r.value=!i.value,l.value=ft(e).split(",").some(u=>{const c=u.includes("not all"),d=u.match(/\(\s*min-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/),f=u.match(/\(\s*max-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/);let p=!!(d||f);return d&&p&&(p=o>=Rl(d[1])),f&&p&&(p=o<=Rl(f[1])),c?!p:p});return}i.value&&(s.value=n.matchMedia(ft(e)),l.value=s.value.matches)}),St(s,"change",a,{passive:!0}),Q(()=>l.value)}const Zo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Yo="__vueuse_ssr_handlers__",lf=af();function af(){return Yo in Zo||(Zo[Yo]=Zo[Yo]||{}),Zo[Yo]}function cf(e,t){return lf[e]||t}function uf(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const df={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Hl="vueuse-storage";function ff(e,t,n,o={}){var i;const{flush:r="pre",deep:s=!0,listenToStorageChanges:l=!0,writeDefaults:a=!0,mergeDefaults:u=!1,shallow:c,window:d=_t,eventFilter:f,onError:p=I=>{console.error(I)},initOnMounted:b}=o,y=(c?dt:ee)(typeof t=="function"?t():t),$=Q(()=>ft(e));if(!n)try{n=cf("getDefaultStorage",()=>_t==null?void 0:_t.localStorage)()}catch(I){p(I)}if(!n)return y;const k=ft(t),B=uf(k),F=(i=o.serializer)!==null&&i!==void 0?i:df[B],{pause:C,resume:g}=Qd(y,I=>M(I),{flush:r,deep:s,eventFilter:f});fe($,()=>A(),{flush:r});let T=!1;const x=I=>{b&&!T||A(I)},z=I=>{b&&!T||X(I)};d&&l&&(n instanceof Storage?St(d,"storage",x,{passive:!0}):St(d,Hl,z)),b?Yi(()=>{T=!0,A()}):A();function w(I,ne){if(d){const G={key:$.value,oldValue:I,newValue:ne,storageArea:n};d.dispatchEvent(n instanceof Storage?new StorageEvent("storage",G):new CustomEvent(Hl,{detail:G}))}}function M(I){try{const ne=n.getItem($.value);if(I==null)w(ne,null),n.removeItem($.value);else{const G=F.write(I);ne!==G&&(n.setItem($.value,G),w(ne,G))}}catch(ne){p(ne)}}function W(I){const ne=I?I.newValue:n.getItem($.value);if(ne==null)return a&&k!=null&&n.setItem($.value,F.write(k)),k;if(!I&&u){const G=F.read(ne);return typeof u=="function"?u(G,k):B==="object"&&!Array.isArray(G)?{...k,...G}:G}else return typeof ne!="string"?ne:F.read(ne)}function A(I){if(!(I&&I.storageArea!==n)){if(I&&I.key==null){y.value=k;return}if(!(I&&I.key!==$.value)){C();try{const ne=F.write(y.value);(I===void 0||(I==null?void 0:I.newValue)!==ne)&&(y.value=W(I))}catch(ne){p(ne)}finally{I?pt(g):g()}}}}function X(I){A(I.detail)}return y}function Gi(e={}){const{document:t=tf}=e;if(!t)return dt("visible");const n=dt(t.visibilityState);return St(t,"visibilitychange",()=>{n.value=t.visibilityState},{passive:!0}),n}function pf(e,t,n={}){const{window:o=_t,...i}=n;let r;const s=Xi(()=>o&&"ResizeObserver"in o),l=()=>{r&&(r.disconnect(),r=void 0)},a=fe(Q(()=>{const c=ft(e);return Array.isArray(c)?c.map(d=>$t(d)):[$t(c)]}),c=>{if(l(),s.value&&o){r=new ResizeObserver(t);for(const d of c)d&&r.observe(d,i)}},{immediate:!0,flush:"post"}),u=()=>{l(),a()};return Ki(u),{isSupported:s,stop:u}}function Fl(e,t={width:0,height:0},n={}){const{window:o=_t,box:i="content-box"}=n,r=Q(()=>{var d;return(d=$t(e))===null||d===void 0||(d=d.namespaceURI)===null||d===void 0?void 0:d.includes("svg")}),s=dt(t.width),l=dt(t.height),{stop:a}=pf(e,([d])=>{const f=i==="border-box"?d.borderBoxSize:i==="content-box"?d.contentBoxSize:d.devicePixelContentBoxSize;if(o&&r.value){const p=$t(e);if(p){const b=p.getBoundingClientRect();s.value=b.width,l.value=b.height}}else if(f){const p=oo(f);s.value=p.reduce((b,{inlineSize:y})=>b+y,0),l.value=p.reduce((b,{blockSize:y})=>b+y,0)}else s.value=d.contentRect.width,l.value=d.contentRect.height},n);Yi(()=>{const d=$t(e);d&&(s.value="offsetWidth"in d?d.offsetWidth:t.width,l.value="offsetHeight"in d?d.offsetHeight:t.height)});const u=fe(()=>$t(e),d=>{s.value=d?t.width:0,l.value=d?t.height:0});function c(){a(),u()}return{width:s,height:l,stop:c}}function hf(e,t,n={}){const{root:o,rootMargin:i="0px",threshold:r=0,window:s=_t,immediate:l=!0}=n,a=Xi(()=>s&&"IntersectionObserver"in s),u=Q(()=>oo(ft(e)).map($t).filter(Wd));let c=On;const d=dt(l),f=a.value?fe(()=>[u.value,$t(o),d.value],([b,y])=>{if(c(),!d.value||!b.length)return;const $=new IntersectionObserver(t,{root:$t(y),rootMargin:i,threshold:r});b.forEach(k=>k&&$.observe(k)),c=()=>{$.disconnect(),c=On}},{immediate:l,flush:"post"}):On,p=()=>{c(),f(),d.value=!1};return Ki(p),{isSupported:a,isActive:d,pause(){c(),d.value=!1},resume(){d.value=!0},stop:p}}function gf(e,t,n={}){const{window:o=_t}=n;return ff(e,t,o==null?void 0:o.localStorage,n)}function vn(e={}){const{window:t=_t,initialWidth:n=Number.POSITIVE_INFINITY,initialHeight:o=Number.POSITIVE_INFINITY,listenOrientation:i=!0,includeScrollbar:r=!0,type:s="inner"}=e,l=dt(n),a=dt(o),u=()=>{if(t)if(s==="outer")l.value=t.outerWidth,a.value=t.outerHeight;else if(s==="visual"&&t.visualViewport){const{width:d,height:f,scale:p}=t.visualViewport;l.value=Math.round(d*p),a.value=Math.round(f*p)}else r?(l.value=t.innerWidth,a.value=t.innerHeight):(l.value=t.document.documentElement.clientWidth,a.value=t.document.documentElement.clientHeight)};u(),Yi(u);const c={passive:!0};return St("resize",u,c),t&&s==="visual"&&t.visualViewport&&St(t.visualViewport,"resize",u,c),i&&fe(sf("(orientation: portrait)"),()=>u()),{width:l,height:a}}class io{static register(t){this.handlers.push(t)}static unregister(t){const n=this.handlers.indexOf(t);n!==-1&&this.handlers.splice(n,1)}static trigger(){for(const t of this.handlers)if(t())return!0;return!1}static clear(){this.handlers=[]}}ie(io,"handlers",[]);function Ji(e){je(()=>io.register(e)),Et(()=>io.unregister(e))}const Wl=ge({__name:"HelpScreen",props:{touchDevice:{type:Boolean}},emits:["hide"],setup(e,{emit:t}){const n=e,o=t,i=ee(null),r=ee([]);Ji(()=>(o("hide"),!0)),je(async()=>{const u=Fl(i),c=mt(()=>{s({width:u.width.value,height:u.height.value})},50);c(),fe(u.width,c),fe(u.height,c)});function s(u){var f;const c=(f=i.value)==null?void 0:f.parentElement;if(!c)return;const d=Array.from(c.querySelectorAll("#controls [title], #top-controls [title], #bottom-controls [title]"));d.length&&(r.value=l(d,u))}function l(u,c){const d=[],f=[];let p=0,b=0;const y=50,$=25;u.forEach(g=>{var M;const T=(M=g.getAttribute("title"))==null?void 0:M.trim(),x=g.getBoundingClientRect();if(!T||!x.height||!x.width)return;const z=Math.ceil((x.top-10)/y),w=Math.ceil((x.left-10)/y);f.push({isTour:!1,title:T,rect:x,fromX:w,toX:Math.max(w+1,Math.ceil((x.right+10)/y)),fromY:z,toY:Math.max(z+1,Math.ceil((x.bottom+10)/y))})}),f.forEach(g=>{for(let T=g.fromY;T<g.toY;T++){d[T]??(d[T]=[]);for(let x=g.fromX;x<g.toX;x++)d[T][x]=g;g.toY>p+1&&(p=g.toY-1),g.toX>b+1&&(b=g.toX-1)}});let k=b/2;f.forEach(g=>{g.isAlignRight=g.fromX>k});const B=(g,T)=>{d[T]??(d[T]=[]);const x=T>=g.toY;if(g.isTour)for(let z=g.fromX;z<g.toX;z++)delete d[g.fromY][z],g.fromY=T,g.toY=T+(x?1:-1),d[T][z]=g;else{const z=g.isAlignRight?g.fromX-3:g.fromX,w=z+3;g.helpItem={fromX:z,toX:w,fromY:T,toY:T+1,isTour:!0,isAlignRight:g.isAlignRight};for(let M=z;M<w;M++)d[T][M]=g.helpItem}},F=(g,T)=>{if(T>p||T<0)return!1;const x=T>=g.toY,z=d[T];if(!z)return B(g,T),!0;const w=z[g.fromX];if(w&&!w.isTour)return!1;if(w&&w.isTour)return F(w,x?T+1:T-1)?(B(g,T),!0):!1;if(!w){const M=g.isAlignRight?-1:1;return z[g.fromX+M]||z[g.fromX+M*2]?F(g,x?T+1:T-1):(B(g,T),!0)}return!1};f.forEach(g=>{if(!F(g,g.toY)){if(g.isAlignRight){const T=d[g.fromY]??[];if(!T.slice(g.fromX-3,g.fromX).filter(Boolean).length){const z=g.fromX-3,w=g.fromX;g.helpItem={isTour:!0,isAlignRight:!0,fromX:z,toX:w,fromY:g.fromY,toY:g.toY};for(let M=g.fromX-3;M<g.fromX;M++)T[M]=g.helpItem;return}}F(g,g.fromY-1)}});const C=[];return f.forEach(g=>{const{title:T,helpItem:x,rect:z,isAlignRight:w,fromX:M,fromY:W,toY:A}=g;if(!T||!x||!z)return;const X=x.fromY>=A,I=x.toY<=W;C.push({title:a(T),style:{top:X?`${z.bottom+(x.fromY-A)*y+$}px`:I?void 0:`${z.top+8}px`,bottom:I?`${c.height-z.top+(x.toY-W)*y+$}px`:void 0,left:w?void 0:`${z.left}px`,right:w?X?`${c.width-z.right}px`:`${c.width-z.right+z.width+$}px`:void 0},arrowStyle:{width:I||X?"2px":`${Math.abs(x.toX-M)*y+$-5}px`,height:I||X?`${(X?x.fromY-A:W-x.toY)*y+$}px`:"2px",top:X?`${z.bottom}px`:I?void 0:`${z.top+20}px`,bottom:I?`${c.height-z.top}px`:void 0,left:w?void 0:`${z.left+z.width/2}px`,right:w?X?`${c.width-z.right+z.width/2}px`:`${c.width-z.right+z.width}px`:void 0}})}),C}function a(u){return n.touchDevice?u.split("(")[0].trim():u}return(u,c)=>(v(),D(we,null,[c[1]||(c[1]=U("div",{class:"fixed inset-0 bg-black bg-opacity-90"},null,-1)),U("div",{ref_key:"root",ref:i,class:"fixed inset-0 z-20 overscroll-contain select-none",onClick:c[0]||(c[0]=Ne(d=>o("hide"),["stop"]))},[(v(!0),D(we,null,Gt(r.value,d=>(v(),D(we,{key:d.title},[U("div",{class:"absolute",style:Te(d.style)},We(d.title),5),U("div",{class:"absolute bg-stone-300 rounded-lg",style:Te(d.arrowStyle)},null,4)],64))),128))],512)],64))}}),mf=Object.freeze(Object.defineProperty({__proto__:null,default:Wl},Symbol.toStringTag,{value:"Module"}));function tn(e,t){let n=null;return(...o)=>{n===null&&(n=setTimeout(()=>{n=null,e(...o)},t))}}const vf=ge({__name:"ReaderTour",emits:["hide"],setup(e,{emit:t}){const n=t,o=ee(null),i=ee(0),r=ee([]),s=Q(()=>r.value[i.value]),l=tn(a,500);je(()=>{const d=Fl(o),f=mt(()=>u({width:d.width.value,height:d.height.value}),50);f(),fe(d.width,f),fe(d.height,f)});function a(){i.value>=r.value.length-1?n("hide"):i.value++}function u(d){const f=c();r.value=f.map(({rect:p,text:b})=>{const y=p.top<d.height-p.bottom,$=p.left<d.width-p.right;return{text:b,style:{left:`${p.left}px`,top:`${p.top}px`,width:`${p.width}px`,height:`${p.height}px`},textStyle:{left:$?`${p.left-12}px`:void 0,right:$?void 0:`${d.width-p.left}px`,top:y?`${p.bottom+12}px`:`${p.top+20}px`,textAlign:y?void 0:"right",transform:y?void 0:"translateY(-50%)"}}}),i.value>=r.value.length&&(i.value=r.value.length-1)}function c(){var p;const d=(p=o.value)==null?void 0:p.parentElement;if(!d)return[];const f=[];return d.querySelectorAll("[data-tour]").forEach(b=>{var k;const y=(k=b.getAttribute("data-tour"))==null?void 0:k.trim();if(!(y!=null&&y.length))return;const $=b.getBoundingClientRect();f.push({rect:$,text:y})}),f}return(d,f)=>{var p,b;return v(),D(we,null,[U("div",{class:de(["fixed inset-0 bg-black bg-opacity-50 duration-500",{"opacity-0":!s.value,"opacity-100":!!s.value}])},null,2),U("div",{ref_key:"root",ref:o,class:"tour",onClick:f[0]||(f[0]=Ne((...y)=>Z(l)&&Z(l)(...y),["stop"]))},[s.value?(v(),D("div",{key:i.value,class:"tour__target",style:Te(s.value.style)},null,4)):ae("",!0),(v(),D("div",{key:i.value,class:"tour__text",style:Te((p=s.value)==null?void 0:p.textStyle)},We(((b=s.value)==null?void 0:b.text)??""),5))],512)],64)}}}),bf=".tour{height:100%;left:0;overflow:hidden;position:fixed;top:0;width:100%;z-index:20}.tour__target{border-radius:9999px;border-width:2px;--tw-border-opacity:1;animation:tour-target-anim .5s forwards;border-color:rgb(120 113 108/var(--tw-border-opacity,1));box-shadow:0 0 0 99999px #000000e6}.tour__target,.tour__text{position:absolute}.tour__text{animation:tour-text-anim 1s forwards,tour-text-bounce .75s ease-in-out infinite alternate;max-width:320px;padding-left:12px;padding-right:12px;transition-duration:1s}@keyframes tour-target-anim{0%{transform:scale(3);--tw-border-opacity:0;opacity:0}to{transform:scale(1);--tw-border-opacity:1;opacity:.9}}@keyframes tour-text-anim{0%{opacity:0}to{opacity:1}}@keyframes tour-text-bounce{0%{margin-top:0}to{margin-top:.625}}",be=(e,t)=>{const n=e.__vccOpts||e;for(const[o,i]of t)n[o]=i;return n},ql=be(vf,[["styles",[bf]]]),yf=Object.freeze(Object.defineProperty({__proto__:null,default:ql},Symbol.toStringTag,{value:"Module"}));function wf({touchDevice:e}){const t=ee(!1);let n=0;return Kn("busy:touchDevice",e),Kn("setBusyState",o=>{n+=o?1:-1;const i=n>0;t.value!=i&&(t.value=i)}),Q(()=>t.value)}function Xo(){const e=Wt("busy:touchDevice"),t=Wt("setBusyState");let n=!1;return Et(()=>{n&&(t==null||t(!1))}),(o,{desktopOnly:i=!1}={})=>{i&&e||(n=o,t==null||t(o))}}function xf(e){Kn("hapticFeedback",e)}function Go(){return Wt("hapticFeedback")}class _f{constructor(){ie(this,"listeners");this.listeners=[],this.onKeyDown=this.onKeyDown.bind(this),this.onKeyUp=this.onKeyUp.bind(this),this.init()}init(){window.addEventListener("keydown",this.onKeyDown,{capture:!0}),window.addEventListener("keyup",this.onKeyUp,{capture:!0}),window.addEventListener("keypress",this.onKeyPress,{capture:!0})}dispose(){window.removeEventListener("keydown",this.onKeyDown,{capture:!0}),window.removeEventListener("keyup",this.onKeyUp,{capture:!0}),window.removeEventListener("keypress",this.onKeyPress,{capture:!0})}onKeyPress(t){t.stopImmediatePropagation(),t.stopPropagation()}onKeyDown(t){var n,o;t.stopImmediatePropagation(),t.stopPropagation();for(let i=0;i<this.listeners.length&&((o=(n=this.listeners[i]).onKeyDown)==null?void 0:o.call(n,t))!==!0;i++);}onKeyUp(t){var n,o;t.stopImmediatePropagation(),t.stopPropagation();for(let i=0;i<this.listeners.length&&((o=(n=this.listeners[i]).onKeyUp)==null?void 0:o.call(n,t))!==!0;i++);}addListener(t){this.listeners.push(t)}removeListener(t){const n=this.listeners.indexOf(t);n!==-1&&this.listeners.splice(n,1)}}function Sf(){const e=new _f;return Et(()=>e.dispose()),Kn("keyController",e),e}function Dt(e){const t=Wt("keyController");je(()=>t.addListener(e)),Et(()=>t.removeListener(e))}function kf(e,t){const n=sessionStorage.getItem("tk:page:path");n!==location.pathname&&(sessionStorage.setItem("tk:page:path",location.pathname),n&&sessionStorage.removeItem("tk:page"));const o=ee(t&&e>0?e:+(sessionStorage.getItem("tk:page")??"0")||e);return Q({get:()=>o.value,set:i=>{o.value=i,sessionStorage.setItem("tk:page",i+"")}})}function Cf(){sessionStorage.removeItem("tk:page"),sessionStorage.removeItem("tk:page:path")}const Tf=(e,t)=>{const n=+(e.getAttribute("data-ripple")??0);if(!n)return;const o=document.createElement("span");let i=1,r=.65;const s=setInterval(a,20);l();function l(){o.style.position="absolute",o.style.height="5px",o.style.width="5px",o.style.borderRadius="100%",o.style.backgroundColor="#f2f2f2",o.style.left=`${t.currentTarget.clientWidth/2}px`,o.style.top=`${t.currentTarget.clientHeight/2}px`,t.currentTarget.appendChild(o)}function a(){const u=+n||50;i<=u?(i++,r-=.65/u,o.style.transform=`scale(${i})`,o.style.opacity=`${r}`):(o.remove(),clearInterval(s))}},zt={mounted:(e,t)=>{e.style.position="relative",e.style.overflow="hidden",e.setAttribute("data-ripple",t.value),e.addEventListener("click",n=>Tf(e,n))},updated:(e,t)=>{e.setAttribute("data-ripple",t.value)}},Pf={class:"group-hover:bg-stone-100 group-hover:bg-opacity-20 transition-bg duration-200 rounđe-full p-2 w-full h-full inline-flex justify-center items-center gap-2 text-base"},Qi=ge({inheritAttrs:!1,__name:"BaseButton",props:{disabled:{type:Boolean},href:{type:String},transparent:{type:Boolean},title:{type:String},enableHapticFeedback:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=e,o=t,i=Xo(),r=Go();let s=!1;function l(){s||(s=!0,i(!0,{desktopOnly:!0}))}function a(){s&&(s=!1,i(!1,{desktopOnly:!0}))}function u(c){n.disabled?c.preventDefault():(o("click",c),n.enableHapticFeedback&&r())}return(c,d)=>He((v(),re(Ps(e.href?"a":"button"),In({href:e.href,title:e.title},{class:["h-10 max-w-full max-h-full rounded-full flex-shrink-0 focus:outline-none outline-none",{"cursor-default opacity-60":e.disabled,"hover:text-stone-100 group duration-200":!e.disabled,"bg-black bg-opacity-50":!e.transparent,[`${c.$attrs.class??""}`]:!0}],onClick:Ne(u,["stop"]),onMouseenter:l,onMouseleave:a}),{default:oe(()=>[U("div",Pf,[ke(c.$slots,"default")])]),_:3},16,["class"])),[[Z(zt),e.disabled?0:15]])}}),If=Object.freeze(Object.defineProperty({__proto__:null,default:Qi},Symbol.toStringTag,{value:"Module"})),Ef={},Mf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Of(e,t){return v(),D("svg",Mf,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M19 12.998h-6v6h-2v-6H5v-2h6v-6h2v6h6z"},null,-1)])])}const Ul=be(Ef,[["render",Of]]),$f=Object.freeze(Object.defineProperty({__proto__:null,default:Ul},Symbol.toStringTag,{value:"Module"})),Df={class:"h-screen w-full flex justify-center items-center relative"},zf={key:0,class:"flex gap-6 p-6 duration-200"},Af={key:0,class:"inline-block rounded-full relative w-28 h-12 overflow-hidden"},Bf={key:0,class:"absolute bottom-0 left-0 right-0 flex justify-center pb-7 md:pb-6 lg:pb-4"},Lf={class:"flex justify-center items-center gap-1 pl-1 pr-2 h-full"},er=be(ge({__name:"AutoNext",props:{hasNext:{type:Boolean},offlineMode:{type:Boolean},seconds:{type:Number},showAddButton:{type:Boolean}},emits:["next","hide","add-to-library","visibility-changed"],setup(e,{emit:t}){const n=e,o=t,i=ee(null),r=ee(!1),s=ee(n.seconds),l=ee(n.seconds<=0),a=ee(n.seconds),u=Go();je(()=>{let f;hf(i,p=>{const b=p.some(y=>y.isIntersecting);b!==r.value&&(r.value=b,o("visibility-changed",b),l.value=n.seconds<=0,s.value=n.seconds,a.value=n.seconds,f&&(clearInterval(f),f=void 0),!(!r.value||l.value)&&(f=setInterval(()=>{s.value-=1,s.value<=0&&(clearInterval(f),f=void 0,o("next"))},1e3)))},{rootMargin:"-108px 0px"}),Et(()=>f&&clearInterval(f))});function c(){o("next"),u()}function d(){o("hide")}return(f,p)=>(v(),D("div",Df,[U("div",{ref_key:"main",ref:i,class:"inline-flex text-base text-stone-300 select-none"},[j(to,{"enter-from-class":"opacity-0","leave-to-class":"opacity-0"},{default:oe(()=>[r.value?(v(),D("div",zf,[e.hasNext?(v(),D("div",Af,[r.value?(v(),D("div",{key:0,class:"absolute left-0 top-0 bottom-0 h-full bg-stone-600 bg-opacity-50",style:Te(l.value?{}:{animation:`auto-next ${a.value}s linear forwards`})},null,4)):ae("",!0),He((v(),D("button",{class:"bg-transparent rounded-full h-full w-full border-solid border-stone-600 border-2 hover:bg-stone-300 hover:bg-opacity-10 totalDuration-200",onClick:Ne(c,["stop"])},[qt(We(l.value?"Next":`Next in ${s.value}`),1)])),[[Z(zt)]])])):ae("",!0),He((v(),D("button",{class:"rounded-full px-6 h-12 bg-transparent border-solid border-stone-600 border-2 hover:bg-stone-300 hover:bg-opacity-10 totalDuration-200",onClick:Ne(d,["stop"])},[qt(We(e.offlineMode?"Close":"Hide"),1)])),[[Z(zt)]])])):ae("",!0)]),_:1})],512),e.showAddButton?(v(),D("div",Bf,[j(Qi,{class:"bg-primary w-min !h-9 !bg-opacity-100",onClick:p[0]||(p[0]=()=>o("add-to-library"))},{default:oe(()=>[U("div",Lf,[j(Ul,{class:"flex-shrink-0 w-auto"}),p[1]||(p[1]=U("span",{class:"text-sm text-stone-50"},"Add to library",-1))])]),_:1})])):ae("",!0)]))}}),[["styles",[".animate-auto-next{animation:auto-next 5s linear forwards}@keyframes auto-next{0%{width:0}to{width:100%}}"]]]),jf=Object.freeze(Object.defineProperty({__proto__:null,default:er},Symbol.toStringTag,{value:"Module"})),Je=ge({inheritAttrs:!1,__name:"ButtonIcon",props:{disabled:{type:Boolean},href:{type:String},title:{type:String},transparent:{type:Boolean},enableHapticFeedback:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;return(o,i)=>(v(),re(Qi,{class:de(["w-10",o.$attrs.class]),disabled:e.disabled,href:e.href,title:e.title,transparent:e.transparent,"enable-haptic-feedback":e.enableHapticFeedback,onClick:i[0]||(i[0]=r=>n("click",r))},{default:oe(()=>[ke(o.$slots,"default")]),_:3},8,["class","disabled","href","title","transparent","enable-haptic-feedback"]))}}),Nf=Object.freeze(Object.defineProperty({__proto__:null,default:Je},Symbol.toStringTag,{value:"Module"})),Vf={},Rf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Hf(e,t){return v(),D("svg",Rf,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"m10.875 19.3l-6.6-6.6q-.15-.15-.213-.325T4 12q0-.2.063-.375t.212-.325l6.6-6.6q.275-.275.688-.287t.712.287q.3.275.313.688T12.3 6.1L7.4 11h11.175q.425 0 .713.288t.287.712q0 .425-.287.713t-.713.287H7.4l4.9 4.9q.275.275.288.7t-.288.7q-.275.3-.7.3t-.725-.3Z"},null,-1)])])}const Kl=be(Vf,[["render",Hf]]),Ff=Object.freeze(Object.defineProperty({__proto__:null,default:Kl},Symbol.toStringTag,{value:"Module"})),tr=ge({__name:"ButtonBack",props:{offlineMode:{type:Boolean},raw:{type:null},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=e,o=t;function i(r){n.offlineMode&&(r.preventDefault(),o("click"))}return(r,s)=>{var l;return v(),re(Je,{href:e.offlineMode||!e.raw?"#":e.raw.title.url,title:`Back to ${((l=e.raw)==null?void 0:l.contentType)===Z(Zt).novel?"novel":"manga"}`,transparent:e.transparent,"enable-haptic-feedback":"",onClick:i},{default:oe(()=>[j(Kl)]),_:1},8,["href","title","transparent"])}}}),Wf=Object.freeze(Object.defineProperty({__proto__:null,default:tr},Symbol.toStringTag,{value:"Module"})),qf={},Uf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Kf(e,t){return v(),D("svg",Uf,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M17.825 8.575q-.2 0-.375-.062t-.325-.213L15.7 6.875q-.3-.3-.3-.712t.3-.688q.275-.3.7-.3t.7.275l.725.725l2.825-2.85q.3-.3.7-.3t.725.3q.275.3.275.725t-.275.7l-3.55 3.55q-.15.15-.325.213t-.375.062ZM6.4 20.4q-.5.2-.95-.087T5 19.475V5q0-.825.588-1.413T7 3h7q-.5.75-.75 1.438T13 6q0 1.8 1.137 3.175T17 10.9q.575.075 1 .075t1-.075v8.575q0 .55-.45.838t-.95.087L12 18l-5.6 2.4Z"},null,-1)])])}const Zl=be(qf,[["render",Kf]]),Zf=Object.freeze(Object.defineProperty({__proto__:null,default:Zl},Symbol.toStringTag,{value:"Module"})),Yf={},Xf={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Gf(e,t){return v(),D("svg",Xf,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M6.4 20.4q-.5.2-.95-.087T5 19.475V5q0-.825.588-1.413T7 3h6v2H7v12.95l5-2.15l5 2.15V11h2v8.475q0 .55-.45.838t-.95.087L12 18l-5.6 2.4ZM7 5h6h-6Zm11 4q-.425 0-.713-.287T17 8V7h-1q-.425 0-.713-.288T15 6q0-.425.288-.713T16 5h1V4q0-.425.288-.713T18 3q.425 0 .713.288T19 4v1h1q.425 0 .713.288T21 6q0 .425-.288.713T20 7h-1v1q0 .425-.288.713T18 9Z"},null,-1)])])}const Yl=be(Yf,[["render",Gf]]),Jf=Object.freeze(Object.defineProperty({__proto__:null,default:Yl},Symbol.toStringTag,{value:"Module"})),nr=ge({__name:"ButtonEntry",props:{entryId:{type:null},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;Dt({onKeyUp:i=>{i.key==="t"&&!i.metaKey&&!i.ctrlKey&&n("click")}});function o(){n("click")}return(i,r)=>(v(),re(Je,{transparent:e.transparent,title:e.entryId?"View entry (T)":"Add to library (T)","data-tour":"Prress here to add to your library",onClick:o},{default:oe(()=>[e.entryId?(v(),re(Zl,{key:0})):(v(),re(Yl,{key:1}))]),_:1},8,["transparent","title"]))}}),Qf=Object.freeze(Object.defineProperty({__proto__:null,default:nr},Symbol.toStringTag,{value:"Module"})),ep={},tp={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function np(e,t){return v(),D("svg",tp,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M16.5 16V8l-4 4l4 4ZM5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h14q.825 0 1.413.588T21 5v14q0 .825-.588 1.413T19 21H5Zm3-2V5H5v14h3Zm2 0h9V5h-9v14Zm-2 0H5h3Z"},null,-1)])])}const Xl=be(ep,[["render",np]]),op=Object.freeze(Object.defineProperty({__proto__:null,default:Xl},Symbol.toStringTag,{value:"Module"})),Jo=ge({inheritAttrs:!1,__name:"ButtonHide",props:{transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;return(o,i)=>(v(),re(Je,{title:"Hide reader","data-tour":"You have entered reader mode, press here to return to the original page",class:de(o.$attrs.class),transparent:e.transparent,onClick:i[0]||(i[0]=()=>n("click"))},{default:oe(()=>[j(Xl)]),_:1},8,["class","transparent"]))}}),ip=Object.freeze(Object.defineProperty({__proto__:null,default:Jo},Symbol.toStringTag,{value:"Module"})),rp={},sp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function lp(e,t){return v(),D("svg",sp,[...t[0]||(t[0]=[U("path",{d:"M199.9 416h-63.8c-4.5 0-8.1-3.6-8.1-8V104c0-4.4 3.6-8 8.1-8h63.8c4.5 0 8.1 3.6 8.1 8v304c0 4.4-3.6 8-8.1 8z",fill:"currentColor"},null,-1),U("path",{d:"M375.9 416h-63.8c-4.5 0-8.1-3.6-8.1-8V104c0-4.4 3.6-8 8.1-8h63.8c4.5 0 8.1 3.6 8.1 8v304c0 4.4-3.6 8-8.1 8z",fill:"currentColor"},null,-1)])])}const or=be(rp,[["render",lp]]),ap=Object.freeze(Object.defineProperty({__proto__:null,default:or},Symbol.toStringTag,{value:"Module"})),cp={},up={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function dp(e,t){return v(),D("svg",up,[...t[0]||(t[0]=[U("path",{d:"M128 104.3v303.4c0 6.4 6.5 10.4 11.7 7.2l240.5-151.7c5.1-3.2 5.1-11.1 0-14.3L139.7 97.2c-5.2-3.3-11.7.7-11.7 7.1z",fill:"currentColor"},null,-1)])])}const ir=be(cp,[["render",dp]]),fp=Object.freeze(Object.defineProperty({__proto__:null,default:ir},Symbol.toStringTag,{value:"Module"})),rr=ge({inheritAttrs:!1,__name:"ButtonPlay",props:{tourMessage:{type:String},playing:{type:Boolean},disabled:{type:Boolean},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=e,o=t;return Dt({onKeyDown(i){!n.disabled&&i.key===" "&&(i.preventDefault(),o("click"))}}),(i,r)=>(v(),re(Je,{transparent:e.transparent,class:de(i.$attrs.class),"data-tour":e.tourMessage,title:`${e.playing?"Pause":"Play"} (Space)`,disabled:e.disabled,onClick:r[0]||(r[0]=()=>o("click"))},{default:oe(()=>[e.playing?(v(),re(or,{key:0})):(v(),re(ir,{key:1}))]),_:1},8,["transparent","class","data-tour","title","disabled"]))}}),pp=Object.freeze(Object.defineProperty({__proto__:null,default:rr},Symbol.toStringTag,{value:"Module"})),hp={},gp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"};function mp(e,t){return v(),D("svg",gp,[...t[0]||(t[0]=[U("g",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2"},[U("circle",{cx:"14",cy:"14",r:"12"}),U("path",{d:"m23 23l7 7M9 12V9h3m4 0h3v3M9 16v3h3m7-3v3h-3"})],-1)])])}const Gl=be(hp,[["render",mp]]),vp=Object.freeze(Object.defineProperty({__proto__:null,default:Gl},Symbol.toStringTag,{value:"Module"})),bp={class:"block w-4 h-4"},yp={class:"w-12"},Jl=ge({__name:"ButtonResetZoom",props:{zoom:{type:Number}},emits:["click"],setup(e,{emit:t}){const n=t;function o(i){n("click",i)}return(i,r)=>(v(),D("button",{class:"h-9 rounded-full inline-flex justify-between items-center bg-black bg-opacity-50 gap-1 py-2 px-3 pointer-events-auto hover:bg-stone-900 hover:bg-opacity-50 duration-200",title:"Reset zoom",onClick:Ne(o,["stop"])},[U("div",bp,[j(Gl)]),U("div",yp,We(Math.ceil(e.zoom*100))+"%",1)]))}}),wp=Object.freeze(Object.defineProperty({__proto__:null,default:Jl},Symbol.toStringTag,{value:"Module"})),xp={},_p={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 36 36"};function Sp(e,t){return v(),D("svg",_p,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"m32.57 15.72l-3.35-1a11.65 11.65 0 0 0-.95-2.33l1.64-3.07a.61.61 0 0 0-.11-.72l-2.39-2.4a.61.61 0 0 0-.72-.11l-3.05 1.63a11.62 11.62 0 0 0-2.36-1l-1-3.31a.61.61 0 0 0-.59-.41h-3.38a.61.61 0 0 0-.58.43l-1 3.3a11.63 11.63 0 0 0-2.38 1l-3-1.62a.61.61 0 0 0-.72.11L6.2 8.59a.61.61 0 0 0-.11.72l1.62 3a11.63 11.63 0 0 0-1 2.37l-3.31 1a.61.61 0 0 0-.43.58v3.38a.61.61 0 0 0 .43.58l3.33 1a11.62 11.62 0 0 0 1 2.33l-1.64 3.14a.61.61 0 0 0 .11.72l2.39 2.39a.61.61 0 0 0 .72.11l3.09-1.65a11.65 11.65 0 0 0 2.3.94l1 3.37a.61.61 0 0 0 .58.43h3.38a.61.61 0 0 0 .58-.43l1-3.38a11.63 11.63 0 0 0 2.28-.94l3.11 1.66a.61.61 0 0 0 .72-.11l2.39-2.39a.61.61 0 0 0 .11-.72l-1.66-3.1a11.63 11.63 0 0 0 .95-2.29l3.37-1a.61.61 0 0 0 .43-.58v-3.41a.61.61 0 0 0-.37-.59ZM18 23.5a5.5 5.5 0 1 1 5.5-5.5a5.5 5.5 0 0 1-5.5 5.5Z",class:"clr-i-solid clr-i-solid-path-1"},null,-1),U("path",{fill:"none",d:"M0 0h36v36H0z"},null,-1)])])}const Ql=be(xp,[["render",Sp]]),kp=Object.freeze(Object.defineProperty({__proto__:null,default:Ql},Symbol.toStringTag,{value:"Module"})),sr=ge({__name:"ButtonSettings",props:{disabled:{type:Boolean},transparent:{type:Boolean}},emits:["click"],setup(e,{emit:t}){const n=t;return Dt({onKeyUp:o=>{o.key==="s"&&!o.metaKey&&!o.ctrlKey&&n("click")}}),(o,i)=>(v(),re(Je,{transparent:e.transparent,title:"Reader preferences (S)",disabled:e.disabled,onClick:i[0]||(i[0]=()=>n("click"))},{default:oe(()=>[j(Ql)]),_:1},8,["transparent","disabled"]))}}),Cp=Object.freeze(Object.defineProperty({__proto__:null,default:sr},Symbol.toStringTag,{value:"Module"})),Tp={},Pp={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function Ip(e,t){return v(),D("svg",Pp,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M4 4h6v2H6v4H4V4Zm10 0h6v6h-2V6h-4V4ZM6 14v4h4v2H4v-6h2Zm14 0v6h-6v-2h4v-4h2Z"},null,-1)])])}const ea=be(Tp,[["render",Ip]]),Ep=Object.freeze(Object.defineProperty({__proto__:null,default:ea},Symbol.toStringTag,{value:"Module"})),Mp={},Op={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function $p(e,t){return v(),D("svg",Op,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M14 20v-6h6v2h-4v4h-2Zm-6 0v-4H4v-2h6v6H8Zm12-10h-6V4h2v4h4v2Zm-10 0H4V8h4V4h2v6Z"},null,-1)])])}const ta=be(Mp,[["render",$p]]),Dp=Object.freeze(Object.defineProperty({__proto__:null,default:ta},Symbol.toStringTag,{value:"Module"})),lr=ge({__name:"ButtonWebFullScreen",props:{transparent:{type:Boolean}},emits:["request-full-screen"],setup(e,{emit:t}){const n=t,o=ee(!1);Dt({onKeyUp:r=>{r.key==="f"&&!r.metaKey&&!r.ctrlKey&&i()}}),St("fullscreenchange",()=>{o.value=!!document.fullscreenElement});function i(){document.fullscreenElement?document.exitFullscreen():n("request-full-screen")}return(r,s)=>(v(),re(Je,{transparent:e.transparent,title:`${o.value?"Exit":"Enter"} fullscreen (F)`,onClick:i},{default:oe(()=>[o.value?(v(),re(ta,{key:0})):(v(),re(ea,{key:1}))]),_:1},8,["transparent","title"]))}}),zp=Object.freeze(Object.defineProperty({__proto__:null,default:lr},Symbol.toStringTag,{value:"Module"})),Ap=["aria-hidden"],Bp=["onClick"],na=ge({__name:"DropdownMenu",props:Xe({items:{type:Array},enableHapticFeedback:{type:Boolean}},{modelValue:{type:Number,required:!1},modelModifiers:{}}),emits:Xe(["select"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=lt(e,"modelValue"),r=ee(null),s=ee(!1),l=ee(!1),a=ee(!1),u=ee(!1),c={mounted:C=>{var g;i.value&&((g=C.children[i.value])==null||g.scrollIntoView({behavior:"auto",block:"center",inline:"center"}))}};Dt({onKeyDown:$}),Ji(()=>{const C=s.value;return C&&(s.value=!1),C});const d=Xo(),f=Go();async function p(C){s.value=C??!s.value,d(s.value),s.value?(b(),B(r.value)):setTimeout(F,250)}function b(){const C=r.value;if(C){const g=C.getBoundingClientRect(),T=g.x+g.width/2;l.value=g.y>window.innerHeight/2,a.value=T<window.innerWidth/3,u.value=T>window.innerWidth/3*2}}function y(C,g){p(),C!=i.value&&(i.value=C,o("select",C,g),n.enableHapticFeedback&&f())}function $(C){s.value&&C.key==="Escape"&&(p(),C.preventDefault())}let k=[];function B(C){const g=window.getComputedStyle(C).zIndex,T=C.style.zIndex;(!g||!(+g>0))&&((!C.parentElement||C.parentElement.childElementCount>1)&&(C.style.zIndex="1",k.push({el:C,zIndex:T})),C.parentElement&&B(C.parentElement))}function F(){k.forEach(({el:C,zIndex:g})=>{C.style.zIndex=g??""}),k=[]}return(C,g)=>(v(),D("div",{ref_key:"root",ref:r,class:"select-none relative inline-flex"},[s.value?(v(),D("div",{key:0,class:"fixed inset-0 bg-transparent",onClick:g[0]||(g[0]=()=>p())})):ae("",!0),e.items.length?(v(),re(to,{key:1,"enter-from-class":"scale-y-90 opacity-0 pointer-events-none","leave-to-class":"scale-y-90 opacity-0 pointer-events-none"},{default:oe(()=>[s.value?He((v(),D("ul",{key:0,ref:"list","aria-hidden":!s.value,class:de(["scrollbar-sm duration-150 delay-50 absolute w-40 max-h-[70vh] list-none bg-stone-800 bg-opacity-80 backdrop-blur-md rounded-lg overflow-auto",{"origin-bottom bottom-full -translate-y-1.5":l.value,"origin-top top-full translate-y-1.5":!l.value,"left-1/2 -ml-20 text-center":!a.value&&!u.value,"right-0 text-right":u.value}]),onWheelPassive:g[1]||(g[1]=Ne(()=>{},["stop"])),onTouchmove:g[2]||(g[2]=Ne(()=>{},["stop"]))},[(v(!0),D(we,null,Gt(e.items,(T,x)=>He((v(),D("li",{key:x,tabindex:"-1",class:de(["h-10 px-4 last:border-b-transparent cursor-pointer hover:bg-stone-100 hover:bg-opacity-10 duration-100",{"text-textPrimary":x===i.value}]),onClick:z=>y(x,z)},[U("div",{class:de(["h-full py-2",{"border-t-[1px] border-solid border-stone-400 border-opacity-30":x>0}])},[ke(C.$slots,"item",{item:T},()=>[qt(We(T),1)])],2)],10,Bp)),[[Z(zt),30]])),128))],42,Ap)),[[c]]):ae("",!0)]),_:3})):ae("",!0),ke(C.$slots,"default",{toggle:p,isOpen:s.value,isAlignTop:l.value})],512))}}),Lp=Object.freeze(Object.defineProperty({__proto__:null,default:na},Symbol.toStringTag,{value:"Module"})),jp={},Np={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Vp(e,t){return v(),D("svg",Np,[...t[0]||(t[0]=[Zu('<circle cx="18" cy="12" r="0" fill="currentColor"><animate attributeName="r" begin=".67" calcMode="spline" dur="1.5s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"></animate></circle><circle cx="12" cy="12" r="0" fill="currentColor"><animate attributeName="r" begin=".33" calcMode="spline" dur="1.5s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"></animate></circle><circle cx="6" cy="12" r="0" fill="currentColor"><animate attributeName="r" begin="0" calcMode="spline" dur="1.5s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"></animate></circle>',3)])])}const oa=be(jp,[["render",Vp]]),Rp=Object.freeze(Object.defineProperty({__proto__:null,default:oa},Symbol.toStringTag,{value:"Module"})),Hp={},Fp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Wp(e,t){return v(),D("svg",Fp,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"m7 10l5 5l5-5z"},null,-1)])])}const ia=be(Hp,[["render",Wp]]),qp=Object.freeze(Object.defineProperty({__proto__:null,default:ia},Symbol.toStringTag,{value:"Module"})),Up=["onClick"],Kp={class:"inline-flex items-center justify-center w-full h-full px-4 rounded-full group-hover:bg-stone-100 group-hover:bg-opacity-20 duration-200"},Zp={class:"whitespace-nowrap"},ar=ge({inheritAttrs:!1,__name:"ButtonDropdown",props:Xe({label:{type:String},title:{type:String},items:{type:Array},disabled:{type:Boolean},canLoadItems:{type:Boolean},loadItems:{type:Function},enableHapticFeedback:{type:Boolean},transparent:{type:Boolean}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:Xe(["select"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=lt(e,"modelValue"),r=ee(!1),s=Xo();async function l(f,p){if(!n.items.length&&(f||await a(),!n.items.length)){p(!1);return}p()}async function a(){r.value||n.items.length||!n.canLoadItems||!n.loadItems||(r.value=!0,await n.loadItems(),r.value=!1)}let u=!1;function c(){u||(u=!0,s(!0,{desktopOnly:!0}))}function d(){u&&(u=!1,s(!1,{desktopOnly:!0}))}return(f,p)=>(v(),re(na,{modelValue:i.value,"onUpdate:modelValue":p[0]||(p[0]=b=>i.value=b),items:e.items,class:de(f.$attrs.class),"enable-haptic-feedback":e.enableHapticFeedback,onSelect:p[1]||(p[1]=(b,y)=>o("select",b,y))},Oi({default:oe(({toggle:b,isOpen:y,isAlignTop:$})=>[He((v(),D("button",In({type:"button",tabindex:"-1",class:["w-full h-10 max-h-full rounded-full group duration-100 transition-bg",{"pointer-events-none opacity-60":e.disabled||r.value,"bg-black bg-opacity-50":!e.transparent,"bg-transparent":e.transparent}]},e.title?{title:e.title}:{},{onClick:Ne(()=>l(y,b),["stop"]),onMouseenter:c,onMouseleave:d}),[U("div",Kp,[U("span",Zp,We(e.label),1),e.items.length||e.canLoadItems?(v(),D("span",{key:0,class:de(["w-4 h-4 flex ml-1 -mr-3 flex-shrink-0",{"rotate-180":$}]),"aria-hidden":"true"},[r.value?(v(),re(oa,{key:0})):(v(),re(ia,{key:1}))],2)):ae("",!0)])],16,Up)),[[Z(zt),30]])]),_:2},[f.$slots.item?{name:"item",fn:oe(({item:b})=>[ke(f.$slots,"item",{item:b})]),key:"0"}:void 0]),1032,["modelValue","items","class","enable-haptic-feedback"]))}}),Yp=Object.freeze(Object.defineProperty({__proto__:null,default:ar},Symbol.toStringTag,{value:"Module"})),Xp={},Gp={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Jp(e,t){return v(),D("svg",Gp,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M15.41 7.41L14 6l-6 6l6 6l1.41-1.41L10.83 12z"},null,-1)])])}const ra=be(Xp,[["render",Jp]]),Qp=Object.freeze(Object.defineProperty({__proto__:null,default:ra},Symbol.toStringTag,{value:"Module"})),eh={},th={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function nh(e,t){return v(),D("svg",th,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M10 6L8.59 7.41L13.17 12l-4.58 4.59L10 18l6-6z"},null,-1)])])}const sa=be(eh,[["render",nh]]),oh=Object.freeze(Object.defineProperty({__proto__:null,default:sa},Symbol.toStringTag,{value:"Module"})),ih={key:0,class:"ml-auto inline-flex gap-[1px] scale-95 origin-right"},cr=ge({__name:"ChapterNav",props:{data:{type:Object},chapterSpec:{type:[Object,String]},touchDevice:{type:Boolean},rtl:{type:Boolean},transparent:{type:Boolean}},emits:["getHiddenChapters","prev","next","dialogOpened"],setup(e,{emit:t}){const n=e,o=t,i=Q(()=>{var d;return typeof n.chapterSpec!="string"&&!!((d=n.chapterSpec)!=null&&d.trigger)});async function r(){const d=typeof n.chapterSpec=="string"?{sel:n.chapterSpec}:n.chapterSpec;if(d){if(d.dialog){await s(d.dialog);return}o("getHiddenChapters"),await gt(50,50,()=>n.data.chapters.length?!0:void 0)}}async function s(d){const f=document.querySelector(d);f&&(f instanceof HTMLDialogElement?f.showModal():f.click(),o("dialogOpened"))}function l(d,f){var p,b,y;(y=(b=(p=n.data)==null?void 0:p.chapters)==null?void 0:b[d])==null||y.select(c(f))}function a(d){n.rtl?o("next",c(d)):o("prev",c(d))}function u(d){n.rtl?o("prev",c(d)):o("next",c(d))}function c(d){return!n.touchDevice&&(d.ctrlKey||d.metaKey)}return(d,f)=>(v(),D(we,null,[j(ar,{modelValue:e.data.activeIndex,label:e.data.activeLabel,title:"Select chapter",transparent:e.transparent,items:e.data.chapters,"can-load-items":i.value,"load-items":r,"enable-haptic-feedback":"",onSelect:l},{item:oe(({item:p})=>[qt(We(p.label),1)]),_:1},8,["modelValue","label","transparent","items","can-load-items"]),e.data.next||e.data.prev?(v(),D("div",ih,[j(Je,{title:`${e.rtl?"Next":"Prev"} chapter (←)`,disabled:e.rtl?!e.data.next:!e.data.prev,transparent:e.transparent,class:"!rounded-r-none","enable-haptic-feedback":"",onClick:a},{default:oe(()=>[j(ra)]),_:1},8,["title","disabled","transparent"]),j(Je,{title:`${e.rtl?"Prev":"Next"} chapter (→)`,disabled:e.rtl?!e.data.prev:!e.data.next,transparent:e.transparent,class:"!rounded-l-none","enable-haptic-feedback":"",onClick:u},{default:oe(()=>[j(sa)]),_:1},8,["title","disabled","transparent"])])):ae("",!0)],64))}}),rh=Object.freeze(Object.defineProperty({__proto__:null,default:cr},Symbol.toStringTag,{value:"Module"})),sh=["min","max","step"],lh={class:"flex-shrink-0 w-12 inline-block text-right"},nn=be(ge({__name:"InputPercentage",props:Xe({min:{type:Number},max:{type:Number},step:{type:Number},format:{type:Function}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=lt(e,"modelValue"),n=Q({get(){return t.value},set(o){t.value=+o}});return(o,i)=>{var r;return v(),D("div",{class:"flex items-center gap-3 pl-1",style:Te({"--percentage":`${(n.value-e.min)/(e.max-e.min)*100}%`})},[He(U("input",{"onUpdate:modelValue":i[0]||(i[0]=s=>n.value=s),type:"range",min:e.min,max:e.max,step:e.step??1,class:"flex-grow",onTouchmove:i[1]||(i[1]=Ne(()=>{},["stop"]))},null,40,sh),[[$d,n.value]]),U("span",lh,We(((r=e.format)==null?void 0:r.call(e,t.value))??t.value),1)],4)}}}),[["styles",["input[type=range]{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:linear-gradient(to right,#fb8252 var(--percentage),#5a5552 var(--percentage));border-radius:9999px;border-style:none;cursor:pointer;height:4px;opacity:.9;pointer-events:none;--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1));outline:2px solid transparent;outline-offset:2px}input[type=range]::-webkit-slider-thumb{-webkit-appearance:none!important;border-radius:9999px;border-style:solid;border-width:2px;cursor:pointer;height:24px;pointer-events:auto;width:24px;--tw-border-opacity:1;border-color:rgb(251 130 82/var(--tw-border-opacity,1));--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1));transition-duration:.2s}input[type=range]:hover{opacity:1}"]]]),ah=Object.freeze(Object.defineProperty({__proto__:null,default:nn},Symbol.toStringTag,{value:"Module"})),ch={ref:"root",class:"flex text-sm flex-wrap gap-2 leading-none"},uh=["onClick","onKeyup"],vt=ge({__name:"InputSelect",props:Xe({items:{type:Array}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=lt(e,"modelValue");function o(i){i!==n.value&&(n.value=i)}return(i,r)=>(v(),D("div",ch,[(v(!0),D(we,null,Gt(t.items,(s,l)=>He((v(),D("div",{key:l,tabindex:"0",class:de(["inline-flex justify-center items-center rounded-full px-3 py-1.5 cursor-pointer z-10 whitespace-nowrap flex-shrink-0 focus:outline-primary hover:bg-opacity-80 duration-200",{"bg-primary":l==n.value,"bg-stone-600 bg-opacity-50":l!=n.value}]),onClick:()=>o(l),onKeyup:[Ko(()=>o(l),["enter"]),Ko(()=>o(l),["space"])]},[qt(We(s),1)],42,uh)),[[Z(zt),30]])),128))],512))}}),dh=Object.freeze(Object.defineProperty({__proto__:null,default:vt},Symbol.toStringTag,{value:"Module"})),fh={class:"flex w-full items-center justify-between cursor-pointer mb-5 last:mb-0"},ph={class:"text-sm py-1"},hh={class:"switcher p-1"},ur=be(ge({__name:"InputSwitcher",props:Xe({label:{type:String}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=lt(e,"modelValue");return(n,o)=>(v(),D("label",fh,[U("span",ph,We(e.label),1),U("div",hh,[He(U("input",{"onUpdate:modelValue":o[0]||(o[0]=i=>t.value=i),type:"checkbox"},null,512),[[Dd,t.value]]),o[1]||(o[1]=U("span",null,null,-1))])]))}}),[["styles",['.switcher{height:24px;position:relative;width:40px}.switcher input{height:0;opacity:0;width:0}.switcher input:checked+span{border-width:1px;--tw-border-opacity:1;border-color:rgb(184 92 56/var(--tw-border-opacity,1));--tw-bg-opacity:1;background-color:rgb(184 92 56/var(--tw-bg-opacity,1))}.switcher input:checked+span:before{bottom:2px;height:18px;left:17.2px;width:18px}.switcher span{border-radius:9999px;border-width:2px;top:0;right:0;bottom:0;left:0;--tw-border-opacity:1;background-color:transparent;border-color:rgb(231 229 228/var(--tw-border-opacity,1))}.switcher span,.switcher span:before{position:absolute;transition-duration:.3s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.switcher span:before{border-radius:9999px;bottom:4px;content:"";height:12px;left:4px;width:12px;--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}']]]),gh=Object.freeze(Object.defineProperty({__proto__:null,default:ur},Symbol.toStringTag,{value:"Module"})),mh={class:"flex-grow mb-5 last:mb-0"},Le=ge({__name:"TableField",props:{label:{type:String},disabled:{type:Boolean}},setup(e){return(t,n)=>(v(),D(we,null,[U("div",{class:de(["flex-shrink-0 mb-2 whitespace-nowrap text-sm",{"opacity-50":e.disabled}])},We(e.label),3),U("div",mh,[ke(t.$slots,"default")])],64))}}),vh=Object.freeze(Object.defineProperty({__proto__:null,default:Le},Symbol.toStringTag,{value:"Module"})),la=ge({__name:"FieldContrast",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=lt(e,"modelValue"),n=Q({get(){return Math.round(t.value*100)},set(o){t.value=Math.round(o)/100}});return(o,i)=>(v(),re(Le,{label:"Contrast"},{default:oe(()=>[j(nn,{modelValue:n.value,"onUpdate:modelValue":i[0]||(i[0]=r=>n.value=r),min:20,max:100,format:r=>`${r}%`},null,8,["modelValue","format"])]),_:1}))}}),bh=Object.freeze(Object.defineProperty({__proto__:null,default:la},Symbol.toStringTag,{value:"Module"})),yh={},wh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function xh(e,t){return v(),D("svg",wh,[...t[0]||(t[0]=[U("path",{d:"M480 358.856V153.143C480 130.512 461.674 112 439.272 112H72.728C50.326 112 32 130.512 32 153.143v205.713C32 381.488 50.326 400 72.728 400h366.545C461.674 400 480 381.488 480 358.856zM112 364V148h288v216H112z",fill:"currentColor"},null,-1)])])}const aa=be(yh,[["render",xh]]),_h=Object.freeze(Object.defineProperty({__proto__:null,default:aa},Symbol.toStringTag,{value:"Module"})),Sh={},kh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function Ch(e,t){return v(),D("svg",kh,[...t[0]||(t[0]=[U("path",{d:"M358.856 32H153.143C130.512 32 112 50.326 112 72.728v366.545C112 461.674 130.512 480 153.143 480h205.713C381.488 480 400 461.674 400 439.272V72.728C400 50.326 381.488 32 358.856 32zM364 400H148V112h216v288z",fill:"currentColor"},null,-1)])])}const ca=be(Sh,[["render",Ch]]),Th=Object.freeze(Object.defineProperty({__proto__:null,default:ca},Symbol.toStringTag,{value:"Module"})),dr=ge({inheritAttrs:!1,__name:"ButtonOutline",emits:["click"],setup(e,{emit:t}){const n=t,o=Go();function i(){o(),n("click")}return(r,s)=>He((v(),D("button",{class:de([r.$attrs.class??"","flex focus:outline-none outline-none rounded-full h-10 justify-center items-center border border-solid border-stone-600 text-stone-200 hover:bg-stone-500 hover:bg-opacity-10 duration-200"]),onClick:i},[ke(r.$slots,"default")],2)),[[Z(zt),24]])}}),Ph=Object.freeze(Object.defineProperty({__proto__:null,default:dr},Symbol.toStringTag,{value:"Module"}));var on=(e=>(e[e.never=0]="never",e[e.move=1]="move",e[e.firstMove=2]="firstMove",e[e.onLoad=3]="onLoad",e))(on||{}),nt=(e=>(e[e.vertical=0]="vertical",e[e.ltr=1]="ltr",e[e.rtl=2]="rtl",e))(nt||{});const Qo=[{name:"System",value:"system-ui, sans-serif"},{name:"Charter",value:'Charter, "Times New Roman", serif'},{name:"Georgia",value:"Georgia, serif"}],ua=ge({__name:"FieldFontFamily",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=lt(e,"modelValue"),n=Q({get(){const o=Qo.findIndex(i=>i.value===t.value);return o===-1?0:o},set(o){t.value=Qo[o].value}});return(o,i)=>(v(),re(Le,{label:"Font family"},{default:oe(()=>[j(vt,{modelValue:n.value,"onUpdate:modelValue":i[0]||(i[0]=r=>n.value=r),items:Z(Qo).map(r=>r.name)},null,8,["modelValue","items"])]),_:1}))}}),Ih=Object.freeze(Object.defineProperty({__proto__:null,default:ua},Symbol.toStringTag,{value:"Module"}));function da(e){if(e)try{return JSON.parse(e)}catch{return}}function Eh(){const{width:e,height:t}=vn();return Q(()=>e.value>t.value)}function fa(e){return String(e).normalize("NFKD").replace(/[\u0300-\u036f]/g,"").trim().toLowerCase().replace(/[^a-z0-9 -]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-")}var At=(e=>(e[e.longStrip=0]="longStrip",e[e.single=1]="single",e[e.double=2]="double",e))(At||{});const ei=.25,ti=5,fr=.25,ni=.2,oi=5,Mh=.05,Oh=0,$h=5;function Dh(e){var g,T,x,z,w,M;const n=e.touchDevice&&(window.innerHeight<=600||window.innerWidth<=600)?Eh():void 0,{titleName:o,isWebtoon:i}=e,r=o?fa(o):location.hostname,s=ee(zh(`tkr:${r}`)),l=W=>{s.value=W;const A=`tkr:${r}`;!W||!Object.keys(W).length?localStorage.removeItem(A):localStorage.setItem(A,JSON.stringify(W))},a=W=>{if(!s.value){l(W);return}const A={...s.value};Object.entries(W).forEach(([X,I])=>{I===void 0?delete A[X]:A[X]=I}),l(A)},u=ee((g=s.value)==null?void 0:g.style),c=ee((T=s.value)==null?void 0:T.direction),d=ee((x=s.value)==null?void 0:x.gap),f=ee((z=s.value)==null?void 0:z.speed),p=ee((w=s.value)==null?void 0:w.zoom),b=ee(((M=s.value)==null?void 0:M.breakFirst)??!1),y=Q({get(){if(i.value)return At.longStrip;if(u.value!==void 0)return u.value;const{landscapeStyle:W,readerStyle:A}=e.defaultPreferences.value;return n!=null&&n.value?W??A:A},set:W=>{if(u.value===W)return;const A=y.value===At.longStrip,X=W===At.longStrip;u.value=W,a({style:W}),A!==X&&($.value=X?nt.vertical:nt.rtl)}}),$=Q({get(){if(i.value)return nt.vertical;if(c.value!==void 0)return c.value;const{direction:W,landscapeDirection:A}=e.defaultPreferences.value;return n!=null&&n.value?A??W:W},set:W=>{c.value=W,a({direction:W})}}),k=Q({get:()=>d.value??e.defaultPreferences.value.gap,set(W){d.value=W,a({gap:W})}}),B=Q({get:()=>f.value??e.defaultPreferences.value.speed,set(W){f.value=W,a({speed:W===1?void 0:W})}}),F=Q({get:()=>p.value??1,set(W){p.value=W,a({zoom:W===1?void 0:W})}}),C=Q({get:()=>b.value,set(W){b.value=W,a({breakFirst:W?!0:void 0})}});return{direction:$,style:y,gap:k,speed:B,zoom:F,isLongStrip:Q(()=>y.value===At.longStrip),isDouble:Q(()=>y.value===At.double),isRTL:Q(()=>$.value===nt.rtl),isVertical:Q(()=>$.value===nt.vertical),breakFirst:C}}function zh(e){const t=localStorage.getItem(e),n=da(t||void 0),o={};return n?(n.style!==void 0&&Object.values(At).includes(n.style)&&(o.style=n.style),n.direction!==void 0&&Object.values(nt).includes(n.direction)&&(o.direction=n.direction),n.gap!==void 0&&n.gap>=Oh&&n.gap<=$h&&(o.gap=n.gap),n.speed!==void 0&&n.speed>=ei&&n.speed<=ti&&(o.speed=n.speed),n.zoom!==void 0&&n.zoom>=ni&&n.zoom<=oi&&(o.zoom=n.zoom),n.breakFirst===!0&&(o.breakFirst=!0),Object.keys(o).length?o:void 0):o}const pr=ge({__name:"NovelPreferencesForm",props:Xe({enableReset:{type:Boolean},defaultPreferences:{type:Object},forceFontFamily:{type:String}},{modelValue:{required:!0},modelModifiers:{}}),emits:Xe(["reset"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=lt(e,"modelValue"),r=Q(()=>Object.keys(i.value).some(l=>{var a;return i.value[l]!==((a=n.defaultPreferences)==null?void 0:a[l])}));function s(l){i.value={...i.value,...l}}return(l,a)=>(v(),D(we,null,[e.forceFontFamily?ae("",!0):(v(),re(ua,{key:0,"model-value":i.value.fontFamily,"onUpdate:modelValue":a[0]||(a[0]=u=>s({fontFamily:u}))},null,8,["model-value"])),j(Le,{label:"Text size"},{default:oe(()=>[j(nn,{"model-value":i.value.fontSize,min:10,max:48,"onUpdate:modelValue":a[1]||(a[1]=u=>s({fontSize:u,lineHeight:Math.max(i.value.lineHeight,u)}))},null,8,["model-value"])]),_:1}),j(Le,{label:"Line height"},{default:oe(()=>[j(nn,{"model-value":i.value.lineHeight,min:10,max:96,step:1,"onUpdate:modelValue":a[2]||(a[2]=u=>s({lineHeight:u,fontSize:Math.min(i.value.fontSize,u)}))},null,8,["model-value"])]),_:1}),j(Le,{label:"Play speed"},{default:oe(()=>[j(nn,{"model-value":i.value.speed,min:Z(ei),max:Z(ti),step:Z(fr),format:u=>`${u.toFixed(2)}x`,"onUpdate:modelValue":a[3]||(a[3]=u=>s({speed:u}))},null,8,["model-value","min","max","step","format"])]),_:1}),e.enableReset?(v(),D("div",{key:1,class:de(["w-full flex justify-center pt-1 duration-200",{"pointer-events-none opacity-0":!r.value,"opacity-90":r.value}])},[j(dr,{class:"w-2/3",onClick:a[4]||(a[4]=()=>o("reset"))},{default:oe(()=>[...a[5]||(a[5]=[qt(" Reset to default ",-1)])]),_:1})],2)):ae("",!0)],64))}}),Ah=Object.freeze(Object.defineProperty({__proto__:null,default:pr},Symbol.toStringTag,{value:"Module"})),Bh={key:1,class:"mb-3 border-stone-500 border-opacity-70"},Lh={key:2,class:"flex justify-end"},jh={class:"h-6 border border-stone-500 rounded-md cursor-pointer flex items-center"},Nh={key:3,class:"mt-5 mb-3 border-stone-500 border-opacity-70"},hr=ge({__name:"DefaultPreferencesForm",props:Xe({touchDevice:{type:Boolean},isNovel:{type:Boolean}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=lt(e,"modelValue"),o=ee(!1),i=ee(!1);je(()=>{o.value=t.touchDevice&&(window.innerHeight<=600||window.innerWidth<=600)});function r(l){const a=i.value,c=(a?n.value.landscapeStyle??n.value.readerStyle:n.value.readerStyle)!==At.longStrip,d=l!==At.longStrip;if(c===d)s(a?{landscapeStyle:l}:{readerStyle:l});else{const f=d?nt.rtl:nt.vertical;s(a?{landscapeStyle:l,landscapeDirection:f}:{readerStyle:l,direction:f})}}function s(l){n.value={...n.value,...l}}return(l,a)=>(v(),D(we,null,[e.isNovel?(v(),D(we,{key:0},[j(pr,{modelValue:n.value,"onUpdate:modelValue":a[0]||(a[0]=u=>n.value=u)},null,8,["modelValue"]),j(la,{"model-value":n.value.contrast,"onUpdate:modelValue":a[1]||(a[1]=u=>s({contrast:u}))},null,8,["model-value"])],64)):(v(),D(we,{key:1},[j(ur,{"model-value":n.value.autoPlay===!0,label:"Auto play in long strip","onUpdate:modelValue":a[2]||(a[2]=u=>s({autoPlay:u}))},null,8,["model-value"]),e.touchDevice?(v(),re(ur,{key:0,"model-value":n.value.pinchToZoom!==!1,label:"Pinch to zoom","onUpdate:modelValue":a[3]||(a[3]=u=>s({pinchToZoom:u}))},null,8,["model-value"])):ae("",!0),o.value?(v(),D("hr",Bh)):ae("",!0),o.value?(v(),D("div",Lh,[U("div",jh,[He((v(),D("button",{class:de(["focus:outline-none outline-none h-full flex justify-center items-center px-3 py-0.5 rounded-l-sm",{"bg-stone-500 text-stone-50":!i.value,"text-stone-400":i.value}]),onClick:a[4]||(a[4]=()=>i.value=!1)},[j(ca)],2)),[[Z(zt),24]]),He((v(),D("button",{class:de(["focus:outline-none outline-none h-full flex justify-center items-center px-3 py-0.5 rounded-r-sm",{"bg-stone-500 text-stone-50":i.value,"text-stone-400":!i.value}]),onClick:a[5]||(a[5]=()=>i.value=!0)},[j(aa)],2)),[[Z(zt),24]])])])):ae("",!0),j(Le,{label:"Style"},{default:oe(()=>[j(vt,{"model-value":i.value?n.value.landscapeStyle??n.value.readerStyle:n.value.readerStyle,items:["Long strip","Single page","Double page"],"onUpdate:modelValue":r},null,8,["model-value"])]),_:1}),j(Le,{label:"Direction"},{default:oe(()=>[j(vt,{"model-value":i.value?n.value.landscapeDirection??n.value.direction:n.value.direction,items:["Vertical","Left to right","Right to left"],"onUpdate:modelValue":a[6]||(a[6]=u=>s(i.value?{landscapeDirection:u}:{direction:u}))},null,8,["model-value"])]),_:1}),o.value?(v(),D("hr",Nh)):ae("",!0),j(Le,{label:"Gap size"},{default:oe(()=>[j(vt,{"model-value":n.value.gap,items:["None","1px","2px","3px","4px","5px"],"onUpdate:modelValue":a[7]||(a[7]=u=>s({gap:u}))},null,8,["model-value"])]),_:1})],64)),j(Le,{label:"Progress size"},{default:oe(()=>[j(vt,{"model-value":n.value.progressSize/2,items:["None","2px","4px","6px","8px","10px"],"onUpdate:modelValue":a[8]||(a[8]=u=>s({progressSize:u*2}))},null,8,["model-value"])]),_:1}),j(Le,{label:"Auto next"},{default:oe(()=>[j(vt,{"model-value":n.value.autoNextSeconds,items:["None","1 sec","2 sec","3 sec","4 sec","5 sec"],"onUpdate:modelValue":a[9]||(a[9]=u=>s({autoNextSeconds:u}))},null,8,["model-value"])]),_:1}),j(Le,{label:"Hide controls"},{default:oe(()=>[j(vt,{"model-value":n.value.hideControlsEvent,items:["Never","On move","On first move","On load"],"onUpdate:modelValue":a[10]||(a[10]=u=>s({hideControlsEvent:u}))},null,8,["model-value"])]),_:1}),e.isNovel?ae("",!0):(v(),D(we,{key:2},[j(Le,{label:"Play speed"},{default:oe(()=>[j(nn,{"model-value":n.value.speed,min:Z(ei),max:Z(ti),step:Z(fr),format:u=>`${u.toFixed(2)}x`,"onUpdate:modelValue":a[11]||(a[11]=u=>s({speed:u}))},null,8,["model-value","min","max","step","format"])]),_:1}),j(Le,{label:e.touchDevice?"Tap zones":"Click zones"},{default:oe(()=>[j(vt,{"model-value":(n.value.tapZone??-1)+1,items:["Default","None","L shaped","Kindle-ish","Edge","Right and left"],"onUpdate:modelValue":a[12]||(a[12]=u=>s({tapZone:u===0?void 0:u-1}))},null,8,["model-value"])]),_:1},8,["label"])],64))],64))}}),Vh=Object.freeze(Object.defineProperty({__proto__:null,default:hr},Symbol.toStringTag,{value:"Module"})),Rh={},Hh={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Fh(e,t){return v(),D("svg",Hh,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M11.3 19.3q-.275-.275-.288-.7t.263-.7l4.9-4.9H5q-.425 0-.713-.288T4 12q0-.425.288-.713T5 11h11.175l-4.9-4.9q-.275-.275-.263-.7t.288-.7q.275-.275.7-.275t.7.275l6.6 6.6q.15.125.213.313t.062.387q0 .2-.062.375t-.213.325l-6.6 6.6q-.275.275-.7.275t-.7-.275Z"},null,-1)])])}const ro=be(Rh,[["render",Fh]]),Wh=Object.freeze(Object.defineProperty({__proto__:null,default:ro},Symbol.toStringTag,{value:"Module"}));var gr=(e=>(e[e.none=0]="none",e[e.lShape=1]="lShape",e[e.kindleIsh=2]="kindleIsh",e[e.edge=3]="edge",e[e.rightAndLeft=4]="rightAndLeft",e))(gr||{});const pa={0:{prevZones:[],nextZones:[]},1:{prevZones:[0,1,2,3],nextZones:[8,7,6,5]},2:{prevZones:[6,3],nextZones:[8,7,5,4]},3:{prevZones:[7],nextZones:[5,0,2,3,6,8]},4:{prevZones:[3,0,6],nextZones:[5,2,8]}},ha=ge({__name:"TapZonePreview",props:{tapZone:{type:Number},direction:{type:Number}},setup(e){const t=e,{width:n,height:o}=vn(),i=Q(()=>Math.min(1.25,Math.max(.75,Math.round(n.value/o.value*100)/100))),r=Q(()=>i.value>=1),s=Q(()=>t.direction===nt.vertical),l=Q(()=>t.direction===nt.rtl),a=Q(()=>{if(!t.tapZone)return;const{prevZones:u,nextZones:c}=pa[t.tapZone];return Array.from({length:9},(d,f)=>{const p=u.includes(f),b=!p&&c.includes(f);return{isPrev:p,isNext:b,hasArrow:f===u[0]||f===c[0]}})});return(u,c)=>(v(),D("div",{class:de(["p-2 bg-black bg-opacity-40 rounded-2xl",{"w-28":r.value,"h-28":!r.value}]),style:Te({"aspect-ratio":i.value})},[e.tapZone===Z(gr).none?(v(),D("div",{key:0,class:de(["inline-block absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 w-14 h-14",{"rotate-90":e.direction===Z(nt).vertical,"rotate-180":e.direction===Z(nt).rtl}])},[j(ro)],2)):a.value?(v(),D("div",{key:2,class:de(["w-full h-full overflow-hidden rounded-xl flex flex-wrap",{"flex-row-reverse":l.value}])},[(v(!0),D(we,null,Gt(a.value,(d,f)=>(v(),D("div",{key:`zone-${f}`,class:de(["w-1/3 h-1/3 flex justify-center items-center p-0.5",{"bg-stone-100":d.isPrev||d.isNext,"bg-opacity-50":d.isPrev}])},[d.hasArrow?(v(),D("span",{key:0,class:"w-5 h-5 max-w-full max-h-full inline-block transform text-stone-800",style:Te({transform:`rotate(${s.value?d.isNext?90:-90:(l.value?d.isPrev:d.isNext)?0:180}deg)`})},[j(ro)],4)):ae("",!0)],2))),128))],2)):(v(),D("div",{key:1,class:de(["w-full h-full overflow-hidden rounded-xl flex flex-nowrap",{"flex-col":s.value}])},[U("div",{class:de(["flex-grow w-full h-full flex justify-center items-center bg-stone-100",{"bg-opacity-50":!l.value}])},[U("span",{class:de(["w-5 h-5 inline-block transform text-stone-800",{"-rotate-90":s.value,"rotate-180":!s.value}])},[j(ro)],2)],2),c[0]||(c[0]=U("div",{class:"flex-grow w-full h-full"},null,-1)),c[1]||(c[1]=U("div",{class:"flex-grow w-full h-full"},null,-1)),U("div",{class:de(["flex-grow w-full h-full flex justify-center items-center bg-stone-100",{"bg-opacity-50":l.value}])},[U("span",{class:de(["w-5 h-5 inline-block text-stone-800",{"transform rotate-90":s.value}])},[j(ro)],2)],2)],2))],6))}}),qh=Object.freeze(Object.defineProperty({__proto__:null,default:ha},Symbol.toStringTag,{value:"Module"})),Uh={key:0,class:"inline-block fixed z-50 left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 pointer-events-none duration-200"},ga=ge({__name:"DirectionToast",props:{direction:{type:Number},tapZone:{type:Number}},setup(e){const t=e,n=sessionStorage.getItem("tk:dir"),o=ee(typeof n!="string"||+n!==t.direction),i=mt(()=>o.value=!1,1500);fe(()=>[t.direction,t.tapZone],()=>{r(),o.value=!0,i()}),je(()=>{r(),i();let s;fe(Gi(),a=>{a!=="visible"?s=Date.now():Date.now()-s>7e3&&(o.value=!0,i())})});function r(){sessionStorage.setItem("tk:dir",t.direction+"")}return(s,l)=>(v(),re(to,{"enter-from-class":"opacity-0","leave-to-class":"opacity-0"},{default:oe(()=>[o.value?(v(),D("div",Uh,[j(ha,{direction:e.direction,"tap-zone":e.tapZone},null,8,["direction","tap-zone"])])):ae("",!0)]),_:1}))}}),Kh=Object.freeze(Object.defineProperty({__proto__:null,default:ga},Symbol.toStringTag,{value:"Module"})),Zh={class:"flex justify-between items-end"},Yh={class:"fixed pointer-events-none left-0 right-0 bottom-0"},ma=ge({__name:"GearControlsLayout",props:{visible:{type:Boolean},spaceTop:{type:null}},setup(e){return(t,n)=>(v(),D("div",{id:"controls",class:de(["fixed pointer-events-none cursor-auto left-0 top-0 w-full h-full flex flex-col justify-between p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3 z-20",{"opacity-100 z-20":e.visible,"opacity-0 -z-10":!e.visible}])},[ke(t.$slots,"default"),U("div",{class:de(["flex gap-1 items-center relative z-30 flex-shrink-0 2xs:gap-3",{"children-pointer-events-auto":e.visible}]),style:Te({paddingTop:`${e.spaceTop||0}px`})},[ke(t.$slots,"top")],6),U("div",Zh,[U("div",{class:de(["inline-block",{"children-pointer-events-auto":e.visible}])},[ke(t.$slots,"bottom-left")],2),U("div",{class:de(["inline-flex flex-col items-end gap-4",{"children-pointer-events-auto":e.visible}])},[ke(t.$slots,"bottom-right")],2)]),U("div",Yh,[ke(t.$slots,"progress")])],2))}}),Xh=Object.freeze(Object.defineProperty({__proto__:null,default:ma},Symbol.toStringTag,{value:"Module"})),Gh='.loading-indicator{display:inline-block;height:80px;position:relative;width:80px}.loading-indicator:after,.loading-indicator:before{border-radius:9999px;border-style:solid;border-width:4px;box-sizing:border-box;display:block;position:absolute;--tw-border-opacity:1;animation:lds-ripple 1s cubic-bezier(0,.2,.8,1) infinite;border-color:rgb(184 92 56/var(--tw-border-opacity,1));content:"";opacity:1}.loading-indicator:after{animation-delay:-.5s}@keyframes lds-ripple{0%{height:0;left:40px;opacity:0;top:40px;width:0}4.9%{height:8px;left:36px;opacity:0;top:36px;width:8px}5%{height:8px;left:36px;opacity:1;top:36px;width:8px}to{height:80px;left:0;opacity:0;top:0;width:80px}}',Jh={},Qh={class:"loading-indicator"};function eg(e,t){return v(),D("div",Qh)}const ii=be(Jh,[["render",eg],["styles",[Gh]]]),tg=Object.freeze(Object.defineProperty({__proto__:null,default:ii},Symbol.toStringTag,{value:"Module"})),ng={class:"max-h-none max-w-none h-full w-full m-0 p-0 border-none outline-none"},og={key:0,class:"fixed inset-0 h-[101%] flex justify-center items-center z-10 bg-black"},mr=be(ge({inheritAttrs:!1,__name:"GearLayout",props:{loading:{type:Boolean},immediate:{type:Boolean},hideCursor:{type:Boolean},style:{type:Object}},setup(e,{expose:t}){const n={mounted:i=>i.isConnected&&!i.open&&i.showModal(),beforeUnmount:i=>i.isConnected&&i.open&&i.close()},o=ee(null);return t({rootEl:o}),(i,r)=>He((v(),D("dialog",ng,[U("div",{ref_key:"rootEl",ref:o,id:"gear-layout",class:de({"cursor-none":e.hideCursor,"cursor-default":!e.hideCursor,"bg-black":e.immediate||!e.loading,"opacity-0":!e.immediate&&e.loading,"duration-200 transition-colors":!e.immediate,[`${i.$attrs.class??""}`]:!0}),style:Te(e.style??{})},[e.loading&&e.immediate?(v(),D("div",og,[j(ii)])):ae("",!0),ke(i.$slots,"default")],6)])),[[n]])}}),[["styles",["#gear-layout{direction:ltr;font-family:Helvetica,sans-serif;font-size:16px;font-weight:400;height:100%;line-height:24px;overflow:hidden;overscroll-behavior:contain;pointer-events:auto;text-align:left;width:100%}"]]]),ig=Object.freeze(Object.defineProperty({__proto__:null,default:mr},Symbol.toStringTag,{value:"Module"})),rg={},sg={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 56 56"};function lg(e,t){return v(),D("svg",sg,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M29.84 49.574h12.398c4.899 0 7.336-2.437 7.336-7.265V13.69c0-4.828-2.437-7.265-7.336-7.265H29.84Zm-16.055 0h12.398V6.426H13.785c-4.875 0-7.36 2.414-7.36 7.265V42.31c0 4.851 2.485 7.265 7.36 7.265"},null,-1)])])}const va=be(rg,[["render",lg]]),ag=Object.freeze(Object.defineProperty({__proto__:null,default:va},Symbol.toStringTag,{value:"Module"})),cg={},ug={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function dg(e,t){return v(),D("svg",ug,[...t[0]||(t[0]=[U("g",{fill:"none"},[U("path",{d:"M24 0v24H0V0zM12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035c-.01-.004-.019-.001-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427c-.002-.01-.009-.017-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093c.012.004.023 0 .029-.008l.004-.014l-.034-.614c-.003-.012-.01-.02-.02-.022m-.715.002a.023.023 0 0 0-.027.006l-.006.014l-.034.614c0 .012.007.02.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z"}),U("path",{fill:"currentColor",d:"M8 3v18H5a2 2 0 0 1-1.995-1.85L3 19V5a2 2 0 0 1 1.85-1.995L5 3zm11 0a2 2 0 0 1 1.995 1.85L21 5v14a2 2 0 0 1-1.85 1.995L19 21h-9V3z"})],-1)])])}const ba=be(cg,[["render",dg]]),fg=Object.freeze(Object.defineProperty({__proto__:null,default:ba},Symbol.toStringTag,{value:"Module"})),pg={key:1,class:"h-5"},ya=ge({__name:"MangaPreferencesForm",props:{direction:{type:Number},readerStyle:{type:Number},gap:{type:Number},speed:{type:Number},zoom:{type:Number},webtoon:{type:Boolean},defaultPreferences:{type:Object},enableReset:{type:Boolean}},emits:["update:reader-style","update:direction","update:gap","update:speed","update:zoom"],setup(e,{emit:t}){const n=e,o=t,i=Q(()=>["Long strip",n.webtoon?void 0:"Single page",n.webtoon?void 0:"Double page"].filter(Boolean)),r=Q(()=>{const a=n.defaultPreferences;return!n.webtoon&&n.readerStyle!==a.readerStyle||!n.webtoon&&n.direction!==a.direction||n.gap!==a.gap||n.speed!==a.speed});function s(a){o("update:zoom",Math.round(a)/100)}function l(){o("update:reader-style",void 0),o("update:direction",void 0),o("update:gap",void 0),o("update:speed",void 0)}return(a,u)=>(v(),D(we,null,[j(Le,{label:"Style"},{default:oe(()=>[j(vt,{"model-value":e.readerStyle,items:i.value,"onUpdate:modelValue":u[0]||(u[0]=c=>o("update:reader-style",c))},null,8,["model-value","items"])]),_:1}),j(Le,{label:"Direction"},{default:oe(()=>[j(vt,{"model-value":e.direction,items:e.webtoon?["Vertical"]:["Vertical","Left to right","Right to left"],"onUpdate:modelValue":u[1]||(u[1]=c=>o("update:direction",c))},null,8,["model-value","items"])]),_:1}),j(Le,{label:"Gap size"},{default:oe(()=>[j(vt,{"model-value":e.gap,items:["None","1px","2px","3px","4px","5px"],"onUpdate:modelValue":u[2]||(u[2]=c=>o("update:gap",c))},null,8,["model-value"])]),_:1}),j(Le,{label:"Play speed"},{default:oe(()=>[j(nn,{"model-value":e.speed,min:Z(ei),max:Z(ti),step:Z(fr),format:c=>`${c.toFixed(2)}x`,"onUpdate:modelValue":u[3]||(u[3]=c=>o("update:speed",c))},null,8,["model-value","min","max","step","format"])]),_:1}),j(Le,{label:"Zoom"},{default:oe(()=>[j(nn,{"model-value":Math.ceil(e.zoom*100),min:Z(ni)*100,max:Z(oi)*100,step:Z(Mh)*100,format:c=>`${Math.ceil(c)}%`,"onUpdate:modelValue":s},null,8,["model-value","min","max","step","format"])]),_:1}),e.enableReset?(v(),D("div",{key:0,class:de(["w-full flex justify-center pt-1 duration-200",{"pointer-events-none opacity-0":!r.value,"opacity-90":r.value}])},[j(dr,{class:"w-2/3",onClick:l},{default:oe(()=>[...u[4]||(u[4]=[qt(" Reset to default ",-1)])]),_:1})],2)):(v(),D("div",pg))],64))}}),hg=Object.freeze(Object.defineProperty({__proto__:null,default:ya},Symbol.toStringTag,{value:"Module"})),wa=ge({__name:"PageNav",props:Xe({disabled:{type:Boolean},pages:{type:Array},totalImgs:{type:Number}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=lt(e,"modelValue"),o=Q(()=>t.pages.map(a=>a.map(({index:u})=>`${u+1}`).join("-"))),i=Q(()=>{const a=n.value,u=t.pages.findIndex(c=>c.some(({index:d})=>d===a));return u===-1?t.pages.length-1:u}),r=Q(()=>t.pages.length?`${o.value[i.value]}/${t.totalImgs}`:"--");function s(a){const u=t.pages[a][0].index;l(u)}function l(a){n.value=a}return(a,u)=>(v(),re(ar,{"model-value":i.value,label:r.value,title:"Current page",items:o.value,disabled:e.disabled,"onUpdate:modelValue":s},null,8,["model-value","label","items","disabled"]))}}),gg=Object.freeze(Object.defineProperty({__proto__:null,default:wa},Symbol.toStringTag,{value:"Module"})),vr=be(ge({__name:"PauseToast",props:{playing:{type:Boolean}},setup(e){const t=e,n=ee(0);return fe(()=>t.playing,()=>{n.value=Date.now()}),(o,i)=>n.value?(v(),D("div",{key:n.value,class:"animate-pause-fade fixed left-1/2 top-1/2 -mx-12 -my-12 pointer-events-none w-24 h-24 p-4 bg-black bg-opacity-40 rounded-full duration-500"},[e.playing?(v(),re(ir,{key:0})):(v(),re(or,{key:1}))])):ae("",!0)}}),[["styles",[".animate-pause-fade{animation:pause-fade .4s linear forwards;transform-origin:center}@keyframes pause-fade{0%{opacity:0;transform:scale(.3)}10%{opacity:1;transform:scale(.35)}55%{opacity:1;transform:scale(.65)}to{opacity:0;transform:scale(1)}}"]]]),mg=Object.freeze(Object.defineProperty({__proto__:null,default:vr},Symbol.toStringTag,{value:"Module"})),vg=30,br=be(ge({__name:"ProgressBar",props:{value:{type:Number},total:{type:Number},longStrip:{type:Boolean},height:{type:Number},rtl:{type:Boolean},opacity:{type:Number}},setup(e){const t=e,n=Q(()=>Math.floor(t.value)+1),o=Q(()=>`${Math.max(2,Math.min(10,t.height))}px`),i=vn().width,r=Q(()=>t.total!==void 0&&i.value/t.total>=vg);return(s,l)=>(v(),D("div",{class:de(["rprog",{"rprog--rtl":e.rtl}]),style:Te({height:o.value,opacity:e.opacity??.8})},[r.value?(v(!0),D(we,{key:0},Gt(e.total,a=>(v(),D("span",{key:a,class:de(["rprog__item",{"rprog__item--active":n.value===a}]),style:Te(!e.longStrip||n.value!==a?{}:{"--portion":`${e.value%1*100}%`})},null,6))),128)):(v(),D("div",{key:1,style:Te({width:`${e.value/(e.total??1)*100}%`}),class:"h-full bg-textPrimary"},null,4))],6))}}),[["styles",['.rprog{--portion:100%;display:flex;width:100%}.rprog--rtl,.rprog--rtl .rprog__item{flex-direction:row-reverse}.rprog__item{display:inline-flex;flex-grow:1;flex-shrink:0;height:100%}.rprog__item:first-child:before{display:none}.rprog__item--active:before,.rprog__item:has(~.rprog__item--active):before{background-color:rgb(0 0 0/var(--tw-bg-opacity,1));content:"";display:block;flex-shrink:0;height:100%;width:1px;--tw-bg-opacity:.25}.rprog__item--active:after,.rprog__item:has(~.rprog__item--active):after{content:"";display:block;height:100%;--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1));width:var(--portion)}']]]),bg=Object.freeze(Object.defineProperty({__proto__:null,default:br},Symbol.toStringTag,{value:"Module"})),xa=ge({__name:"GesturesContainer",props:{spaceTop:{type:Number},controlsVisible:{type:Boolean},zoom:{type:Number},zooming:{type:Boolean},pinchToZoome:{type:Boolean},tapZone:{type:Number},pageIndex:{type:Number},playController:{type:Object},rtl:{type:Boolean},horizontal:{type:Boolean},longStrip:{type:Boolean},touchDevice:{type:Boolean},busy:{type:Boolean}},emits:["update:zoom","update:zooming","dragEnd","click","prev","next"],setup(e,{expose:t,emit:n}){const o=e,i=n,r=ee(null),s=ee(Math.min(oi,Math.max(ni,o.zoom))),l=ee(!1),a=ee(!1),u={isZoomIn:!1,isZoomOut:!1,initial:void 0};t({rootEl:r}),fe(()=>o.zoom,P=>G(P)),je(()=>{o.touchDevice?St(r,"touchstart",k):(St(r,"mousedown",p),St(window,"wheel",x))}),Dt({onKeyDown:P=>{var _;if(!o.busy&&((_=r.value)==null||_.focus(),!(P.key==="Meta"||P.key==="Control")&&(P.ctrlKey||P.metaKey)))switch(P.key){case"0":G(1);break;case"-":G(s.value-.2),P.preventDefault();break;case"=":case"+":G(s.value+.2),P.preventDefault();break}},onKeyUp:P=>{o.zooming&&!(P.ctrlKey||P.metaKey)&&X()}});function c(P){a.value!==P&&(a.value=P,P?o.playController.pause():(i("dragEnd"),o.playController.resume()))}let d={x:0,y:0},f={x:0,y:0};function p(P){if(P.button!==0)return;const _=r.value;_&&(d={x:P.clientX,y:P.clientY},f={x:_.scrollLeft,y:_.scrollTop},window.addEventListener("mousemove",b),window.addEventListener("mouseup",()=>{window.removeEventListener("mousemove",b),setTimeout(()=>c(!1))},{once:!0}),P.preventDefault(),P.stopPropagation())}function b(P){const _=P.clientX-d.x,Y=P.clientY-d.y;if(!a.value&&Math.abs(_)<.5&&Math.abs(Y)<.5)return;c(!0);const se=r.value;se&&(se.scrollLeft=f.x-_,se.scrollTop=f.y-Y)}let y={distance:0,zoom:s.value,x:0,y:0},$=!1;function k(P){o.busy||($=o.pinchToZoome&&P.touches.length===2,$&&(i("update:zooming",!0),c(!0),P.stopPropagation(),P.preventDefault(),y={distance:z(P),zoom:s.value,x:(P.touches[0].clientX+P.touches[1].clientX)/2,y:(P.touches[0].clientY+P.touches[1].clientY)/2}),($||o.longStrip&&o.playController.isPlaying.value)&&window.addEventListener("touchend",B,{once:!0}))}function B(){var se;if($=!1,o.zooming){c(!1),X();return}if(!a.value)return;const P=mt(()=>{var K;c(!1),(K=r.value)==null||K.removeEventListener("scroll",Y)},200),_=setTimeout(P,200);(se=r.value)==null||se.addEventListener("scroll",Y);function Y(){clearTimeout(_),P()}}function F(P){if(!$&&!(o.longStrip&&o.playController.isPlaying.value)||(c(!0),!o.zooming)||(P.stopPropagation(),P.preventDefault(),P.touches.length<2))return;const Y=z(P)/y.distance;ne(Math.ceil(Y*y.zoom*100)/100,y)}const C=mt(()=>l.value=!1,100);let g=!1;const T=mt(()=>{g=!1},30);function x(P){if(o.busy)return;let _=o.zooming;if(g||(g=!0,_=P.ctrlKey||P.metaKey,_&&i("update:zooming",!0)),T(),_){P.stopPropagation(),P.preventDefault();const Y=Math.ceil((s.value+P.deltaY*-.01)*100)/100;ne(Y,{x:P.clientX,y:P.clientY});return}o.horizontal&&(l.value||(l.value=!0),C(),P.deltaY&&(r.value&&(r.value.scrollLeft+=P.deltaY*(o.rtl?-1:1)),P.stopPropagation()))}function z(P){return Math.hypot(P.touches[0].clientX-P.touches[1].clientX,P.touches[0].clientY-P.touches[1].clientY)}const w={x:0,y:0,ts:0};function M(P){if(a.value||o.zooming)return;const _=r.value;if(!_||W(_,P)||(i("click"),o.playController.isPlaying.value))return;const{clientX:Y,clientY:se}=P,{x:K,y:R,ts:Pe}=w;w.x=Y,w.y=se,w.ts=new Date().getTime();const ye=w.ts-Pe;ye>250||ye<10||Math.abs(K-Y)>40||Math.abs(R-se)>40||(w.ts=0,w.x=0,w.y=0,A(Y,se))}function W(P,_){if(o.playController.isPlaying.value)return!1;const Y=o.tapZone;if(Y===gr.none)return!1;const se=o.controlsVisible?o.spaceTop:0,K=P.clientHeight-se,R=Math.max(0,_.clientY-se),Pe=o.horizontal?P.clientWidth:K;let ye=!1,pe=!1;if(Y){const{prevZones:ve,nextZones:xe}=pa[o.tapZone],Be=Math.floor(R/K*3);let Qe=Math.floor(_.clientX/P.clientWidth*3);o.rtl&&(Qe=2-Qe);const Ae=Be*3+Qe;ye=ve.includes(Ae),pe=!ye&&xe.includes(Ae)}else{const xe=(o.horizontal?o.rtl?Pe-_.clientX:_.clientX:R)/Pe,Be=o.horizontal?.2:.15;ye=xe<=Be&&o.pageIndex>0,pe=!ye&&xe>=1-Be}if(!ye&&!pe)return!1;if(o.longStrip){const ve=(ye?-1:1)*.75*Pe;o.horizontal?P.scrollLeft=P.scrollLeft+(o.rtl?-1:1)*ve:P.scrollTop=Math.max(0,P.scrollTop+ve)}else ye?i("prev"):pe&&i("next");return!0}async function A(P,_){const Y=s.value===1?2:1;await G(Y,{x:P,y:_}),X()}function X(){i("update:zooming",!1),u.initial=void 0,u.isZoomIn=!1,u.isZoomOut=!1}function I(){if(u.initial)return;const P=r.value;if(!P)return;const _=P.querySelector(`[data-index="${o.pageIndex}"],[data-index2="${o.pageIndex}"]`)??void 0;_&&(u.initial={el:_,rect:_.getBoundingClientRect()})}function ne(P,_){if(u.isZoomIn=u.isZoomIn||!u.isZoomOut&&P>1,u.isZoomIn&&P<1){G(1,_);return}if(u.isZoomOut=u.isZoomOut||!u.isZoomIn&&P<1,u.isZoomOut&&P>1){G(1,_);return}G(P,_)}async function G(P,_){const Y=r.value,se=Math.min(oi,Math.max(ni,P));if(!Y||s.value===se)return;I();const{initial:K}=u;if(!K)return;const R=(_==null?void 0:_.x)??Y.clientWidth/2,Pe=(_==null?void 0:_.y)??Y.clientHeight/2;s.value=se,i("update:zoom",se),await pt();const{el:ye,rect:pe}=K,ve=ye.offsetWidth/pe.width,xe=ye.offsetHeight/pe.height;Y.scrollLeft=ye.offsetLeft-pe.left*ve+R*(ve-1),Y.scrollTop=ye.offsetTop-pe.top*xe+Pe*(xe-1)}return(P,_)=>(v(),D("div",{ref_key:"rootEl",ref:r,tabindex:"0",class:de(["w-full h-full overflow-auto scrollbar-none overscroll-contain scrollbar-none focus:outline-none touch-pan-x touch-pan-y",{"!snap-none":!e.longStrip&&(a.value||l.value||e.zooming),"cursor-grabbing":!e.touchDevice&&a.value,"overflow-hidden":e.zooming}]),style:Te({"font-size":`${s.value}px`}),onClick:Ne(M,["stop"]),onTouchmoveCapture:Ne(F,["stop"])},[ke(P.$slots,"default")],38))}}),yg=Object.freeze(Object.defineProperty({__proto__:null,default:xa},Symbol.toStringTag,{value:"Module"})),wg=["src"],yr=ge({inheritAttrs:!1,__name:"ReaderImg",props:{src:{type:null},style:{type:Object}},setup(e){const t=e;let n;const o={mounted:i=>{if(t.src instanceof HTMLElement){const r=t.src.getBoundingClientRect();n=document.createElement("div"),n.style.setProperty("width",`${r.width}px`),n.style.setProperty("height",`${r.height}px`),t.src.replaceWith(n),i.appendChild(t.src)}},beforeUnmount:i=>{const r=i.children[0];n&&r&&(n.replaceWith(r),n=void 0)}};return(i,r)=>typeof e.src=="string"?(v(),D("img",{key:0,src:e.src,class:de(i.$attrs.class??""),style:Te(e.style)},null,14,wg)):He((v(),D("div",{key:1,class:de(i.$attrs.class??""),style:Te(e.style)},null,6)),[[o]])}}),xg=Object.freeze(Object.defineProperty({__proto__:null,default:yr},Symbol.toStringTag,{value:"Module"}));function wr(e,t){return(e==null?void 0:e.querySelector(`[data-index="${t}"],[data-index2="${t}"]`))??void 0}const _g=["data-index"],Sg={key:0,class:"rbod__page rbod__page--loading"},kg=["data-index"],_a=be(ge({__name:"ReaderBody",props:{page:{type:Number},pageIndex:{type:Number},direction:{type:Number},isLongStrip:{type:Boolean},isVertical:{type:Boolean},isDouble:{type:Boolean},isRTL:{type:Boolean},pages:{type:Array},totalImgs:{type:Number},gap:{type:Number},zoom:{type:Number},zooming:{type:Boolean},pinchToZoome:{type:Boolean},tapZone:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},playController:{type:Object},busy:{type:Boolean},controlsVisible:{type:Boolean}},emits:["ready","update:zoom","update:zooming","update:playing","dragEnd","click","end","prev","next"],setup(e,{expose:t,emit:n}){const o=e,i=n,r=ee(null),s=Q(()=>{var g;return(g=r.value)==null?void 0:g.rootEl});t({rootEl:s});const l=vn(),a=Q(()=>{const{width:g,height:T}=l,x=o.isLongStrip?o.isVertical?g.value:T.value:Math.min(g.value,T.value);return Math.min(4,Math.max(1,Math.ceil(x/400-1)))*o.gap}),u=ee(o.isLongStrip?{min:o.pageIndex-1,max:o.pageIndex}:B()),c=ee(o.pageIndex-1),d=Q(()=>{const{min:g,max:T}=u.value,x={};for(let z=g;z<=T;z++)x[z]=!0;return x}),f=ee(b()),p=tn(()=>{f.value=b(),pt(()=>$())},100);fe(l.width,p),fe(l.height,p),fe(()=>o.pages,p),fe(()=>o.isLongStrip,p),fe(()=>o.isVertical,p);function b(){const g=l.width.value,T=l.height.value,{pages:x,isLongStrip:z,isVertical:w}=o;return x.map(M=>{var Y;const W=M.some(se=>!se.img),A=M.map(se=>se.index),X={isLoading:W,indexes:A,visible:!1};if(W)return X;const I=M.map(({img:se})=>se).filter(Boolean);if(!I.length||(X.srcs=I.map(({src:se})=>se),I.every(se=>se.hasError)))return X;const G=(Y=I.find(se=>!se.hasError))==null?void 0:Y.size;if(!G)return X;const P=I.reduce((se,K)=>{var R;return se+(((R=K.size)==null?void 0:R.width)??G.width)},0),_=I.reduce((se,K)=>{var R;return se+(((R=K.size)==null?void 0:R.height)??G.height)},0)/I.length;return z&&w||!z&&g/P<T/_?(X.width=Math.min(g,P),X.height=_*(X.width/P)):(X.height=Math.min(T,_),X.width=P*(X.height/_)),X.width&&X.height&&(X.style={width:`${X.width}em`,height:`${X.height}em`}),X})}const y=Q(()=>{const g=o.isVertical?"width":"height";return f.value.map(T=>T[g]).filter(Boolean).sort((T,x)=>x-T)[0]});je(()=>{const g=wr(s.value,o.pageIndex);g==null||g.scrollIntoView({behavior:"instant",block:"start"});let T,x=!1;Ys(()=>{T!==o.pageIndex&&(T=o.pageIndex,$(),x||(x=!0,pt(()=>i("ready"))))})});async function $(){const g=o.isLongStrip?k():B();g&&(g.min!==u.value.min||g.max!==u.value.max)&&(u.value=g,g.min<c.value&&(c.value=g.min))}function k(){var w,M;const g=Math.floor(o.page),T=wr(s.value,g);if(!T)return;const x=(w=F(T))==null?void 0:w.getAttribute("data-index"),z=(M=C(T))==null?void 0:M.getAttribute("data-index");return{min:x?parseInt(x):Math.max(0,g-2),max:z?parseInt(z):f.value.length-1}}function B(){const{pageIndex:g}=o;return{min:Math.max(0,g-(o.isDouble?5:3)),max:g+(o.isDouble?6:3)}}function F(g,T=0){const x=g.previousElementSibling;if(!x)return;const z=T+(o.isVertical?x.clientHeight:x.clientWidth);return(o.isVertical?z>l.height.value*1.5:o.isRTL?z>l.width.value*2.5:z>l.width.value*1.5)?x:F(x,z)}function C(g,T=0){const x=g.nextElementSibling;if(!x)return;const z=T+(o.isVertical?x.clientHeight:x.clientWidth);return(o.isVertical?z>l.height.value*3.5:o.isRTL?z>l.width.value*1.5:z>l.width.value*2.5)?x:C(x,z)}return(g,T)=>(v(),re(xa,{ref_key:"gestureContainer",ref:r,"space-top":e.spaceTop,"controls-visible":e.controlsVisible,zoom:e.zoom,zooming:e.zooming,"pinch-to-zoome":e.pinchToZoome,"tap-zone":e.tapZone,"page-index":e.pageIndex,class:de(["rbod",{"rbod--long-strip":e.isLongStrip,"rbod--paging":!e.isLongStrip,"rbod--vertical":e.isVertical,"rbod--rtl":e.isRTL,"rbod--1page":f.value.length===1}]),"play-controller":e.playController,horizontal:!e.isVertical,rtl:e.isRTL,"touch-device":e.touchDevice,busy:e.busy,"long-strip":e.isLongStrip,style:Te({"--gap":`${a.value}em`,"--space-top":`${e.spaceTop}px`,"--screen-width-em":Z(l).width.value+"em","--screen-height-em":Z(l).height.value+"em",...e.isLongStrip?{"--max-size-em":y.value+"em"}:{}}),"onUpdate:zoom":T[0]||(T[0]=x=>i("update:zoom",x)),"onUpdate:zooming":T[1]||(T[1]=x=>i("update:zooming",x)),onDragEnd:T[2]||(T[2]=()=>i("dragEnd")),onClick:T[3]||(T[3]=()=>i("click")),onPrev:T[4]||(T[4]=()=>i("prev")),onNext:T[5]||(T[5]=()=>i("next"))},{default:oe(()=>[(v(!0),D(we,null,Gt(f.value,x=>{var z;return v(),D("div",In({key:e.direction+"_"+x.indexes[0],"data-index":x.indexes[0]},{ref_for:!0},x.indexes.length>1?{"data-index2":x.indexes[1]}:{}),[!((z=x.srcs)!=null&&z.length)||x.isLoading||c.value>x.indexes[0]?(v(),D("div",Sg,[d.value[x.indexes[0]]?(v(),re(ii,{key:0})):ae("",!0)])):x.srcs.length==1?(v(),D(we,{key:1},[d.value[x.indexes[0]]?(v(),re(yr,{key:1,class:"rbod__page img",src:x.srcs[0],style:Te(x.style)},null,8,["src","style"])):(v(),D("div",{key:0,class:"rbod__page",style:Te(x.style)},null,4))],64)):(v(),D("div",{key:2,class:de(["rbod__page rbod__page--double",{"flex-row-reverse":e.isRTL}]),style:Te(x.style)},[x.indexes.some(w=>d.value[w])?(v(!0),D(we,{key:0},Gt(x.srcs,(w,M)=>(v(),D("div",{key:typeof w=="string"?w:`${M}-${x.height}`},[j(yr,{src:w,class:"img"},null,8,["src"])]))),128)):ae("",!0)],6))],16,_g)}),128)),U("div",{class:"last","data-index":e.totalImgs},[ke(g.$slots,"end")],8,kg)]),_:3},8,["space-top","controls-visible","zoom","zooming","pinch-to-zoome","tap-zone","page-index","play-controller","horizontal","rtl","touch-device","busy","long-strip","class","style"]))}}),[["styles",[".rbod{--tw-translate-y:0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@media (min-width:1024px){.rbod{transform:none}}.rbod--rtl{flex-direction:row-reverse}.rbod.rbod--vertical>div{padding:calc(var(--gap)/2) 0}.rbod:not(.rbod--vertical){align-items:center;display:flex;height:100%;justify-content:flex-start}.rbod:not(.rbod--vertical)>div{padding:0 calc(var(--gap)/2)}.rbod--long-strip.rbod--vertical.rbod--1page>div:first-child{min-height:100vh}.rbod--long-strip.rbod--vertical>div:first-child{margin-top:var(--space-top);padding-top:0}.rbod--long-strip.rbod--vertical>div:last-child{padding-bottom:0}.rbod--long-strip.rbod--vertical>div{width:var(--max-size-em)}.rbod--long-strip.rbod--vertical .rbod__page--loading{height:75vh;width:100%}.rbod--long-strip.rbod--vertical .last{height:100vh}.rbod--long-strip:not(.rbod--vertical).rbod--1page>div:first-child{min-width:100vw}.rbod--long-strip:not(.rbod--vertical)>div{align-items:center;display:flex;height:var(--max-size-em)}.rbod--long-strip:not(.rbod--vertical) .rbod__page--loading{height:100%;max-width:100vw;width:680px}.rbod--long-strip:not(.rbod--vertical) .last{width:100vw}.rbod--long-strip>div>.img{flex-shrink:0;margin:auto}.rbod--paging>div{align-items:center;display:grid;justify-content:center;min-height:100vh;min-width:100vw;scroll-snap-align:center;scroll-snap-stop:always}.rbod--paging.rbod--vertical{scroll-snap-type:y var(--tw-scroll-snap-strictness);--tw-scroll-snap-strictness:mandatory}.rbod--paging.rbod--vertical>div{width:var(--screen-width-em)}.rbod--paging:not(.rbod--vertical){scroll-snap-type:x var(--tw-scroll-snap-strictness);--tw-scroll-snap-strictness:mandatory}.rbod--paging:not(.rbod--vertical)>div{height:var(--screen-height-em)}.rbod--paging .rbod__page--loading{height:100%;width:100%}.rbod--paging .rbod__page.rbod__page--double{align-items:center;background-color:transparent;display:flex;gap:var(--gap);justify-content:center}.rbod--paging .rbod__page.rbod__page--double div{display:flex;height:100%;-webkit-user-select:none;-moz-user-select:none;user-select:none;--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.rbod--paging .rbod__page.rbod__page--double div .img{flex-shrink:0;max-height:100%;max-width:100%;-o-object-fit:contain;object-fit:contain}.rbod>div{flex-shrink:0}.rbod .rbod__page,.rbod>div{margin:auto;-webkit-user-select:none;-moz-user-select:none;user-select:none}.rbod .rbod__page{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1));-o-object-fit:contain;object-fit:contain}.rbod .rbod__page--loading{align-items:center;background-color:transparent;display:flex;justify-content:center}.rbod .img canvas,.rbod .img img{height:100%;max-height:100%;max-width:100%;width:100%}"]]]),Cg=Object.freeze(Object.defineProperty({__proto__:null,default:_a},Symbol.toStringTag,{value:"Module"})),Tg={},Pg={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Ig(e,t){return v(),D("svg",Pg,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M19 6.41L17.59 5L12 10.59L6.41 5L5 6.41L10.59 12L5 17.59L6.41 19L12 13.41L17.59 19L19 17.59L13.41 12z"},null,-1)])])}const Sa=be(Tg,[["render",Ig]]),Eg=Object.freeze(Object.defineProperty({__proto__:null,default:Sa},Symbol.toStringTag,{value:"Module"})),Mg={class:"flex w-full flex-shrink-0 justify-between items-center h-16 px-3"},ka=ge({__name:"BottomSheet",props:Xe({spaceTop:{type:Number}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=lt(e,"modelValue"),n=ee(null),o=ee(!1),i=ee(0);Dt({onKeyDown:s});const r=Xo();fe(t,c=>r(c)),Ji(()=>{const c=t.value;return c&&(t.value=!1),c});function s(c){t.value&&c.key==="Escape"&&(t.value=!1,c.preventDefault())}const l={y:-1};function a(c){const d=n.value;if(!d)return;if(d.scrollTop>0){l.y=-1;return}if(l.y===-1){l.y=Math.max(0,c.touches[0].clientY);return}const p=c.touches[0].clientY-l.y,b=p>0?p:0;b!=i.value&&(i.value=b);const y=b>0;y!==o.value&&(o.value=y)}async function u(){o.value=!1,l.y=-1,await pt();const c=n.value;c&&c.offsetHeight-i.value<window.innerHeight/2&&i.value>c.offsetHeight*.3&&(t.value=!1),i.value=0}return(c,d)=>(v(),D("div",{class:de(["fixed inset-0 flex flex-col items-center justify-end select-none z-40 text-stone-100",{"!pointer-events-none":!t.value}]),style:Te({"padding-top":(e.spaceTop??0)+60+"px"}),onClick:d[3]||(d[3]=()=>t.value=!1)},[j(to,{"enter-from-class":"!translate-y-full","leave-to-class":"!translate-y-full"},{default:oe(()=>[t.value?(v(),D("div",{key:0,class:de(["w-full sm:w-[31rem] bg-stone-900 bg-opacity-90 backdrop-blur-md rounded-t-xl max-w-full overflow-hidden shadow-lg shadow-neutral-950",{"duration-0":o.value,"duration-200":!o.value}]),style:Te(i.value?{transform:`translateY(${i.value}px)`}:{}),onClick:d[1]||(d[1]=Ne(()=>{},["stop"])),onWheelPassive:d[2]||(d[2]=Ne(()=>{},["stop"])),onTouchmove:Ne(a,["stop"]),onTouchend:u},[U("div",Mg,[j(Je,{transparent:"",onClick:d[0]||(d[0]=()=>t.value=!1)},{default:oe(()=>[j(Sa)]),_:1}),ke(c.$slots,"name"),ke(c.$slots,"actions")]),U("div",{ref_key:"scrollEl",ref:n,class:de(["overflow-auto overscroll-none px-6 md:px-8 lg:px-10 xl:px-12 pt-1.5 pb-8 md:pb-6 flex-grow scrollbar-sm",{"overflow-hidden":o.value}]),style:{"max-height":"calc(100% - 4rem)"}},[ke(c.$slots,"default")],2)],38)):ae("",!0)]),_:3})],6))}}),Og=Object.freeze(Object.defineProperty({__proto__:null,default:ka},Symbol.toStringTag,{value:"Module"})),$g=["onClick","onKeyup"],Ca=be(ge({__name:"TabBar",props:Xe({items:{type:Array}},{modelValue:{type:Number,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=lt(e,"modelValue"),o=ee(null),i=ee({width:"",left:""}),r=ee(!1);je(()=>{const l=Date.now();fe(n,async a=>{var c;await pt();const u=(c=o.value)==null?void 0:c.children[a+1];u&&(i.value={width:u.offsetWidth+"px",left:u.offsetLeft+"px"},!r.value&&Date.now()-l>500&&(r.value=!0),u.scrollIntoView({behavior:r.value?"smooth":"auto",block:"center",inline:"center"}))},{immediate:!0})});function s(l){n.value=l}return(l,a)=>(v(),D("div",{ref_key:"root",ref:o,class:"relative h-8 rounded-[2.5rem] inline-flex bg-black bg-opacity-50 p-1 font-medium max-w-full leading-none overflow-auto scrollbar-none",style:{}},[U("div",{class:de(["bg-stone-300 h-6 rounded-2xl absolute top-1 pointer-events-none",{"duration-200":r.value}]),style:Te(i.value)},null,6),(v(!0),D(we,null,Gt(t.items,(u,c)=>He((v(),D("div",{key:c,tabindex:"0",class:de(["text-sm inline-flex justify-center items-center h-6 rounded-2xl px-4 cursor-pointer relative z-10 whitespace-nowrap flex-shrink-0 focus:outline-primary hover:bg-stone-50 hover:bg-opacity-10 duration-200",{"text-stone-900":c==n.value,"text-stone-400":c!=n.value}]),onClick:Ne(()=>s(c),["stop"]),onKeyup:[Ko(()=>s(c),["enter"]),Ko(()=>s(c),["space"])]},[qt(We(u),1)],42,$g)),[[Z(zt),30]])),128))],512))}}),[["styles",[".scrollbar-none{scrollbar-width:none}.scrollbar-none::-webkit-scrollbar{display:none}"]]]),Dg=Object.freeze(Object.defineProperty({__proto__:null,default:Ca},Symbol.toStringTag,{value:"Module"})),zg={},Ag={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"};function Bg(e,t){return v(),D("svg",Ag,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10s10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8s8 3.59 8 8s-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5c0-2.21-1.79-4-4-4z"},null,-1)])])}const Ta=be(zg,[["render",Bg]]),Lg=Object.freeze(Object.defineProperty({__proto__:null,default:Ta},Symbol.toStringTag,{value:"Module"})),jg={},Ng={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 28 28"};function Vg(e,t){return v(),D("svg",Ng,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M14 8.25a2.25 2.25 0 1 1 0-4.5a2.25 2.25 0 0 1 0 4.5m0 8a2.25 2.25 0 1 1 0-4.5a2.25 2.25 0 0 1 0 4.5M11.75 22a2.25 2.25 0 1 0 4.5 0a2.25 2.25 0 0 0-4.5 0"},null,-1)])])}const Pa=be(jg,[["render",Vg]]),Rg=Object.freeze(Object.defineProperty({__proto__:null,default:Pa},Symbol.toStringTag,{value:"Module"})),Hg={key:1,class:"w-full text-center text-xl whitespace-nowrap text-ellipsis flex-shrink overflow-hidden px-5 select-text"},Fg={class:"opacity-90"},Wg={key:0,class:"w-full text-center text-sm text-stone-400 whitespace-nowrap text-ellipsis flex-shrink overflow-hidden mb-3 -mt-2 select-text px-4"},xr=ge({__name:"SettingsBottomSheet",props:Xe({name:{type:String},spaceTop:{type:Number},enableHelp:{type:Boolean},enableDefaultPreferences:{type:Boolean}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:Xe(["help","more"],["update:modelValue"]),setup(e,{emit:t}){const n=e,o=t,i=lt(e,"modelValue"),r=ee(0),s=Q(()=>n.name??location.hostname);Dt({onKeyUp:a=>{a.key==="s"&&!a.metaKey&&!a.ctrlKey&&(i.value=!0)}}),je(()=>{fe(i,a=>{a||setTimeout(()=>{r.value!==0&&(r.value=0)},300)})});function l(){o("help"),i.value=!1}return(a,u)=>(v(),re(ka,{modelValue:i.value,"onUpdate:modelValue":u[2]||(u[2]=c=>i.value=c),"space-top":e.spaceTop},{name:oe(()=>[e.enableDefaultPreferences?(v(),re(Ca,{key:0,modelValue:r.value,"onUpdate:modelValue":u[0]||(u[0]=c=>r.value=c),items:["Preferences","Default"]},null,8,["modelValue"])):(v(),D("h3",Hg,We(s.value),1))]),actions:oe(()=>[e.enableDefaultPreferences?(v(),re(Je,{key:0,transparent:"",class:de(e.enableHelp?"":"opacity-0 pointer-events-none"),onClick:l},{default:oe(()=>[U("span",Fg,[j(Ta)])]),_:1},8,["class"])):(v(),re(Je,{key:1,transparent:"",onClick:u[1]||(u[1]=()=>o("more"))},{default:oe(()=>[j(Pa)]),_:1}))]),default:oe(()=>[r.value===0?(v(),D(we,{key:0},[e.enableDefaultPreferences?(v(),D("h3",Wg,We(s.value),1)):ae("",!0),ke(a.$slots,"tab-preferences")],64)):(v(),D(we,{key:1},[ke(a.$slots,"tab-default"),u[3]||(u[3]=U("div",{class:"h-6"},null,-1))],64))]),_:3},8,["modelValue","space-top"]))}}),qg=Object.freeze(Object.defineProperty({__proto__:null,default:xr},Symbol.toStringTag,{value:"Module"}));function bn(e,t){if(e instanceof HTMLOptionElement){const n=e.parentElement instanceof HTMLOptGroupElement?e.parentElement.parentElement:e.parentElement;if(!n||!(n instanceof HTMLSelectElement))return;const o=e.getAttribute("value")||"";if(n.value===o)return;n.value=o,n.dispatchEvent(new Event("change"));return}e instanceof HTMLAnchorElement&&(t==null?void 0:t.preventDefault)!==!1&&e.addEventListener("click",n=>n.preventDefault(),{once:!0}),e.click(),e.dispatchEvent(new PointerEvent("pointerdown",{bubbles:!0,cancelable:!0,pointerType:"mouse",button:0})),e.dispatchEvent(new MouseEvent("mousedown",{bubbles:!0,cancelable:!0,view:window,button:0}))}const Ug={text:Oa,attr:Jg,"attr-contain":Qg,value:em,row:tm,"bg-image":nm,json:om},Kg={pattern:im,remove:rm,atob:sm,json:$a};function Ia(e,t){if(e)return Zg(e,t,Xg)}function Zg(e,t,n){if(!e)return;const o=e.split("||").map(i=>i.trim()).filter(Boolean);for(const i of o){const r=Yg(i);if(!r)continue;const s=n(document.documentElement,r);if(s)return s}}function Yg(e){const[t,n,...o]=e.split("|");if(!n)return;const i=n!=null&&n.startsWith("[")&&n.endsWith("]")?n.substring(1,n.length-1).split(","):[n];return{selector:t||void 0,extractors:i.map(Ea),transformers:o.map(Ea)}}function Ea(e){const t=e.indexOf(":"),n=t!==-1;return{fn:n?e.substring(0,t):e,param:n?e.substring(t+1):""}}function Xg(e,t){if(!t.selector)return Ma(e,t);const n=lm(t.selector);for(const o of n){const i=Array.from(e.querySelectorAll(o));for(const r of i){const s=Ma(r,t);if(s)return s}}}function Ma(e,t){for(const n of t.extractors){const o=Ug[n.fn],i=o(e,n.param);if(i)return Gg(i,t.transformers)}}function Gg(e,t){var o;let n=e;for(const i of t){if(!n)return;const r=Kg[i.fn];r&&(n=(o=r(n,i.param))==null?void 0:o.trim())}return n}function Oa(e){return Array.from(e.childNodes).filter(n=>n.nodeType===3).map(n=>yn(n.textContent)).filter(Boolean).join(" ").trim()||yn(e.textContent)}function Jg(e,t){return yn(e.getAttribute(t))}function Qg(e,t){let n=e.getAttribute(t);if(!n){const o=e.getAttributeNames().find(i=>i.includes(t));o&&(n=e.getAttribute(o))}return yn(n)}function em(e){return e.value}function tm(e,t){var i,r,s;if(!t)return;const n=(i=yn(e.textContent))==null?void 0:i.toLowerCase(),o=t.toLowerCase();if(!(n!==o&&n!==`${o}:`))return yn(((r=e.nextElementSibling)==null?void 0:r.textContent)??((s=e.nextSibling)==null?void 0:s.textContent))}function nm(e){const t=getComputedStyle(e).backgroundImage;if(!(!t||!t.startsWith("url(")))return t.slice(5,-2)||void 0}function om(e,t){const n=Oa(e);if(n)return $a(n,t)}function $a(e,t){const n=Da(da(e),t),o=typeof n;if(o==="string")return yn(n)||e;if(o==="number"||o==="boolean")return n+""}function Da(e,t){if(!e||!t)return;const n=t.indexOf("."),o=n!==-1,i=o?t.substring(0,n):t,r=o?t.substring(n+1):void 0;try{const s=e[i];return r?Da(s,r):s}catch{return}}function yn(e){if(e)return(e==null?void 0:e.replace(/(\n|\t)/g," ").trim())||void 0}function im(e,t){if(t)try{return e.replace(new RegExp(t,"i"),"$1")}catch{}return e}function rm(e,t){if(t)try{return e.replaceAll(new RegExp(t,"gi"),"")}catch{}return e}function sm(e){try{return window.atob(e)}catch{return e}}function lm(e){const t=[];let n="",o=!1;for(let r=0;r<e.length;r++){const s=e[r];if(s==="["?o=!0:s==="]"&&(o=!1),s===","&&!o){const l=n.trim();l.length>0&&t.push(l),n=""}else n+=s}const i=n.trim();return i.length>0&&t.push(i),t}function _r(e,t){const n=t??document;if(e.startsWith("//")){const i=document.evaluate(e,document,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue;return i instanceof HTMLElement?i:void 0}return n.querySelector(e)??void 0}function wn(e=0){return new Promise(t=>setTimeout(t,e))}const Sr={};async function kr(e){am();const t=(()=>{const r=e.width,s=e.height;if(r&&s)return{width:r,height:s};const l=e.getBoundingClientRect();return{width:l.width,height:l.height}})(),n=await za(e);if(n)return{size:t,src:n};const o=cm(e);if(!o)return;const i=await za(o);if(i)return{size:t,src:i}}function am(){var o,i;if(Sr.toBlob)return;const e=document.createElement("template");e.innerHTML="<iframe></iframe>";const t=e.content.querySelector("iframe");t&&(t==null||t.style.setProperty("style","none"),document.body.appendChild(t));const n=(i=(o=t==null?void 0:t.contentWindow)==null?void 0:o.HTMLCanvasElement)==null?void 0:i.prototype;Sr.toBlob=(n==null?void 0:n.toBlob)??HTMLCanvasElement.prototype.toBlob,t&&document.body.removeChild(t)}function cm(e){var o;const t=e.cloneNode(),n=(o=t.getContext)==null?void 0:o.call(t,"2d");if(n){try{n.drawImage(e,0,0)}catch{return}return t}}function za(e){return new Promise(t=>{const n=o=>{if(!o)return t(void 0);const i=URL.createObjectURL(o);t(i)};try{Sr.toBlob.call(e,n,"image/jpeg",1)}catch{t(void 0)}})}async function Aa({src:e,onSize:t,resolveOnSizeDetected:n}){return new Promise(o=>{const i=new Image;let r=!1,s;const l=setInterval(()=>{const{naturalWidth:a,naturalHeight:u}=i;if(u&&a)if(clearInterval(l),mn(a,u)){s={width:a,height:u};const c={src:e,size:s};t==null||t(c),n&&o(c)}else i.onload=()=>{},r=!0,o(void 0)},20);i.onerror=()=>{clearInterval(l),o({src:e,hasError:!0})},i.onload=()=>setTimeout(()=>!r&&o(s?{src:e,size:s}:void 0),30),i.src=e})}let ri;async function Ba({el:e,src:t,onSize:n,resolveOnSizeDetected:o}){if(t.startsWith("blob:")){const r=await um(e,t);return r&&(n==null||n(r)),r}if((e==null?void 0:e.src)===t&&e.naturalWidth&&e.naturalHeight){const r={width:e.naturalWidth,height:e.naturalHeight};if(mn(r.width,r.height)){const s={src:t,size:r};return n==null||n(s),o||e.complete||await gt(150,100,()=>e.complete||void 0),s}return}return await Aa({src:t,onSize:n,resolveOnSizeDetected:o})}async function um(e,t){const n=e.naturalWidth,o=e.naturalHeight;if(!mn(n,o))return;if(ri===void 0)try{(await fetch(t)).ok&&(ri=!0)}catch{}if(!ri)ri=!1;else return{src:t,size:{width:n,height:o}};const i=document.createElement("canvas"),r=i.getContext("2d");return i.width=n,i.height=o,r==null||r.drawImage(e,0,0,n,o),await kr(i)}async function La(e){const{lstrip:t,lstripBtn:n}=e||{};if(!t||!n||!!_r(t))return!1;const i=n.split(";");for(const r of i)if(!await dm(r.trim()))return!1;return!0}async function dm(e){const t=await gt(50,30,()=>_r(e));return t?(bn(t),await wn(),!0):!1}function Cr(e){return Array.from(e.querySelectorAll("img:not(nav img, header img, footer img, aside img),canvas"))}class ja{constructor(){ie(this,"id",0)}dispose(){this.id++}async run(t){const n=++this.id;await t(()=>n!==this.id)}}class Tr{constructor(t){ie(this,"initialPage");ie(this,"onInitialPageChanged");ie(this,"onAsyncImgsChanged");this.initialPage=t.initialPage,this.onInitialPageChanged=t.onInitialPageChanged,this.onAsyncImgsChanged=t.onAsyncImgsChanged}}class fm extends Tr{constructor(n){super(n);ie(this,"asyncImgs",[]);ie(this,"contentSel");ie(this,"contentEl");ie(this,"pagingSpec");ie(this,"currentPageIndex",0);ie(this,"isDisposed",!1);ie(this,"allDownloaded",!1);ie(this,"downloadingIndex");ie(this,"onError");ie(this,"imgsCache",new Map);ie(this,"canvasCache",new Map);ie(this,"onPageChangedSingleThread",new ja);ie(this,"onAsyncImgsChangedThrottled");this.contentSel=n.contentSel,this.pagingSpec=n.pagingSpec,this.onError=n.onError,this.onAsyncImgsChangedThrottled=tn(o=>o.length&&n.onAsyncImgsChanged(o),50),(async()=>{if(await La(n.spec),this.isDisposed)return;const o=await gt(200,50,()=>{const r=si(n.pagingSpec.current);return r&&r>0?r-1:void 0});if(o===void 0){n.onError();return}if(this.isDisposed||(this.currentPageIndex=o,await this.observeTotal(),this.isDisposed))return;const i=n.initialPage!==void 0?Math.min(this.asyncImgs.length-1,n.initialPage):o;n.initialPage!==i&&n.onInitialPageChanged(i),await this.downloadCurrentPages(Math.floor(i))})()}dispose(n){if(this.isDisposed=!0,this.onPageChangedSingleThread.dispose(),n!==void 0){const o=this.findPageBtn(Math.floor(n));o&&bn(o)}}onPageIndexChanged(n,o){this.downloadCurrentPages(o)}setAsyncImgs(n){this.asyncImgs=Array.from({length:n}).map((o,i)=>o??this.asyncImgs[i]),this.allDownloaded=this.asyncImgs.every(Boolean)}async observeTotal(){let n=await gt(100,50,()=>{const r=si(this.pagingSpec.total);return r&&r<2e3?r:void 0});if(!n){this.onError();return}this.setAsyncImgs(n);let o=0;const i=setInterval(()=>{if(this.isDisposed){clearInterval(i);return}const r=si(this.pagingSpec.total);if(!r||n===r){o=0;return}n=r,this.onTotalChanged(r),++o===50&&clearInterval(i)},200)}onTotalChanged(n){this.setAsyncImgs(n),this.onAsyncImgsChangedThrottled(this.asyncImgs),this.downloadCurrentPages(this.currentPageIndex)}async downloadCurrentPages(n){this.allDownloaded||this.downloadingIndex!==n&&(this.downloadingIndex=n,await this.onPageChangedSingleThread.run(async o=>{const i=[n-1,n+3,n+2,n+1,n];for(const r of i)if(!(r<0||r>=this.asyncImgs.length)&&(await this.navigateToPage(r,o),o()||r!==this.currentPageIndex||(await this.downloadPageImg(this.currentPageIndex,o),o())))return;this.downloadingIndex=void 0}))}async navigateToPage(n,o){if(n===this.currentPageIndex)return;const i=this.findPageBtn(n);if(i&&(await this.clickNavigateBtn(i,n,o),o()||this.currentPageIndex===n))return;const{prevBtn:r,nextBtn:s}=this.pagingSpec;if(!r||!s)return;const l=n-this.currentPageIndex>0,a=l?s:r,u=document.querySelector(a);if(!u)return;const c=this.currentPageIndex+(l?1:-1);await this.clickNavigateBtn(u,c,o),!(o()||this.currentPageIndex!==c)&&await this.navigateToPage(n,o)}async clickNavigateBtn(n,o,i){for(let r=0;r<20;r++){bn(n);for(let s=0;s<6;s++){await wn(50);const l=si(this.pagingSpec.current);if(l&&(this.currentPageIndex=l-1,this.currentPageIndex===o)||i())return}}}async downloadPageImg(n,o){var r;const i=await this.findContentEl();if(!(o()||!i))for(let s=0;s<400;s++){const l=(r=this.pagingSpec)==null?void 0:r.img,a=l?i.querySelector(l):Cr(i).find(c=>Mn(c,i)&&mn(c.width,c.height));if(!a){if(await wn(50),o())return;continue}const u=await this.downloadImageEl(a,n,o);if(o())return;(u!=null&&u.size||u!=null&&u.hasError)&&this.setAsyncImg(n,u);break}}async findContentEl(){if(this.contentEl&&this.contentEl.isConnected)return this.contentEl;const n=this.contentSel;if(n)return await gt(100,10,()=>{for(const o of n.split(",")){const i=document.querySelector(o);if(i)return this.contentEl=i,i}})}setAsyncImg(n,o){n>=0&&n<this.asyncImgs.length&&o!==this.asyncImgs[n]&&(this.asyncImgs.splice(n,1,o),this.onAsyncImgsChangedThrottled([...this.asyncImgs]))}async downloadImageEl(n,o,i){if(n instanceof HTMLCanvasElement){const l=this.canvasCache.get(n);if(l)return l;const a=await kr(n);return a&&this.canvasCache.set(n,a),a}let r,s=0;for(let l=0;l<300;l++){const a=n.src,u=await(async()=>{const c=this.imgsCache.get(a);if(c){if(r!==a&&(r=a,s=0),(c==null?void 0:c.index)!==o){if(++s<10)return;this.imgsCache.set(a,{...c,index:o})}return c.asyncImg}const d=await Ba({el:n,src:a,resolveOnSizeDetected:!0});return this.imgsCache.set(a,{index:o,asyncImg:d}),d})();if(!u){if(await wn(100),i())return;continue}return u}}findPageBtn(n,o){const{pageBtn:i}=this.pagingSpec;if(i)return o!=null&&o.isConnected?o:_r(i.replaceAll("{page}",`${n+1}`),document.body)}}function si(e,t){return pm(Ia(e,t))}function pm(e){if(e)return parseInt(e.replace(/\D*/,""))||void 0}function hm(e,t){let n=[t??document.documentElement];const o=e.split("->");for(let i=0;i<o.length;i++){const r=o[i];n=n.map(s=>Array.from((s.shadowRoot??s).querySelectorAll(r))).flat()}return n}const gm=3;class Na{constructor(t){ie(this,"download");ie(this,"key");ie(this,"threads");ie(this,"runningItems",[]);ie(this,"completedItems");ie(this,"promisesMap",new Map);this.download=t.download,this.key=t.key}dispose(){var t;(t=this.threads)==null||t.dispose(),this.threads=void 0,this.completedItems=void 0}run(t){var s;const{activeIndex:n}=t;t.items&&(this.runningItems=t.items);const o=this.runningItems;if(this.completedItems===o)return;this.completedItems=void 0,(s=this.threads)==null||s.dispose();let i=Math.max(0,n-1),r=!0;this.threads=new mm(gm,()=>{const l=o[i];if(!l){this.completedItems=o;return}r&&i===o.length-1?(r=!1,i=n-2):r?i++:i--;const a=this.key?this.key(l):l;if(a){const u=this.promisesMap.get(a);if(u)return u;const c=this.download(l,a);return this.promisesMap.set(a,c),c}}),this.threads.exec()}}class mm{constructor(t,n){ie(this,"isDisposed",!1);this.limit=t,this.getNext=n}dispose(){this.isDisposed=!0}exec(){for(let t=0;t<this.limit;t++)this.next()}async next(){if(this.isDisposed)return;const t=this.getNext();t&&(await t,await wn(20),this.next())}}function vm(e,t){let n;return()=>{n&&clearTimeout(n),n=setTimeout(()=>{e(),n=void 0},t)}}class Pr{constructor(t){ie(this,"callback");ie(this,"isDisposed",!1);ie(this,"unobserveMap",new Map);this.callback=t}dispose(){this.isDisposed=!0,this.clear()}clear(){for(const t of this.unobserveMap.values())t()}observe(t){if(this.unobserveMap.has(t.el))return;const n=this.observeInternal(t,()=>{!this.isDisposed&&this.unobserveMap.has(t.el)&&this.callback(t)});this.unobserveMap.set(t.el,n)}unobserve(t){var n;(n=this.unobserveMap.get(t.el))==null||n(),this.unobserveMap.delete(t.el)}}class bm extends Pr{observeInternal({el:t},n){const o=t.getContext("2d");if(!o)return()=>{};const i=o.drawImage.bind(o),r=o.putImageData.bind(o),s=vm(()=>{n()},120),l=(a,u,c)=>(s(),Reflect.apply(a,u,c));try{o.drawImage=new Proxy(i,{apply:l}),o.putImageData=new Proxy(r,{apply:l})}catch{}return()=>{try{o.drawImage=i,o.putImageData=r}catch{}}}}class ym{constructor(t,n){ie(this,"contentEl",document.body);ie(this,"contentSel");ie(this,"cb");ie(this,"isDisposed",!1);this.contentSel=t,this.cb=n}dispose(){this.isDisposed=!0}async load(t){const n=this.contentSel;if(!n){this.cb(document.body);return}let o=await gt(t?100:1,10,()=>{for(const s of n.split(",")){const l=document.querySelector(s);if(l)return l}});if(!o)return;this.contentEl=o,this.cb(o);let i=0;const r=async()=>{if(!this.isDisposed&&!(o!=null&&o.isConnected)){if(i=0,o=await gt(50,20,()=>{const s=document.querySelector(n);return s!=null&&s.isConnected&&s!==o?s:void 0}),!o||o===this.contentEl)return;this.contentEl=o,this.cb(o)}!this.isDisposed||++i>=10||setTimeout(r,200)};setTimeout(r,200)}}class wm extends Pr{observeInternal(t,n){const o=()=>{n(),this.unobserve(t)};return t.el.addEventListener("load",o),()=>t.el.removeEventListener("load",n)}}class xm extends Pr{observeInternal({el:t},n){let o=t.getAttribute("src");const i=new MutationObserver(r=>{r.some(l=>{if(l.attributeName!=="src")return!1;const a=o;return o=t.getAttribute("src"),!!o&&a!==o})&&n()});return i.observe(t,{attributes:!0}),()=>i.disconnect()}}function Va(e,t){const n=(o,i)=>{if(!o)return;const{offsetTop:r,offsetParent:s}=o;if(s&&r&&i.set(s,Math.max(i.get(s)??0,r)),!(o===t||o.scrollHeight-o.clientHeight>=10&&window.getComputedStyle(o).overflow!=="visible"))return n(o.parentElement,i);let a=0;return i.forEach((u,c)=>{a+=c===s?u-r:u}),{el:o,top:a}};return n(e,new Map)}const li="mp-scroll-container";class _m{constructor(){ie(this,"scrollEl")}dispose(){var t;(t=this.scrollEl)==null||t.classList.remove(li)}scrollTo({rawImages:t,page:n,skipIfVisible:o,isScrollDown:i,isScrollExact:r,fallbackScrollEl:s}){var $;const l=Math.floor(n),a=t[Math.min(t.length-1,l)];if(!a)return;const u=a.el??a.parentEl;if(!u)return;const c=u.getBoundingClientRect();if(o&&c.top<=0&&c.top+c.height>0)return;const d=Va(u,s);if(!d)return;const{el:f,top:p}=d;s!==document.documentElement&&!f.classList.contains(li)&&(f!==this.scrollEl&&(($=this.scrollEl)==null||$.classList.remove(li),this.scrollEl=f),f.classList.add(li));const b=n>=t.length?c.height:r?n%1*c.height:i?Math.max(0,c.height-window.innerHeight/2):-window.innerHeight/2,y={top:p+b,behavior:"instant"};f.scrollTo(y),f!==document.documentElement&&document.documentElement.scrollTo(y)}}function Sm(e){const t=new Set,n=e.getAttributeNames(),o=n.indexOf("src"),i=o!==-1;i&&(n.splice(o,1),n.push("src"));for(const r of n){if(r==="srcset"||i&&r===":src"||r!=="data-url"&&r!=="data-original"&&!r.includes("src"))continue;const s=e.getAttribute(r);s&&(r==="src"&&e.naturalWidth&&e.naturalWidth<200||t.add(s.replace(/(\n|\t)/g," ").trim()))}return Array.from(t)}class km extends Tr{constructor(n){var s,l;super(n);ie(this,"spec");ie(this,"rawImages",[]);ie(this,"validRawImages",[]);ie(this,"isDisposed",!1);ie(this,"loadRawImagesThread",new ja);ie(this,"isRawImagesLoadedOnce",!1);ie(this,"isScrolledOnce",!1);ie(this,"currentPageIndex");ie(this,"isIOS");ie(this,"asyncImgsMap",new Map);ie(this,"disconnectObservers");ie(this,"submitAsyncImgsThrottled");ie(this,"contentElLoader");ie(this,"imgLoadOnceObserver",new wm(()=>this.reloadRawImages()));ie(this,"autoDownloadQueue",new Na({download:(n,o)=>this.downloadImageEl({el:o,parentEl:n.parentEl}),key:n=>n.el}));ie(this,"scroller",new _m);ie(this,"canvasObserver",new bm(n=>{this.downloadImageEl(n)}));ie(this,"imgSrcObserver",new xm(n=>{this.downloadImageEl(n)}));ie(this,"reloadRawImages",mt(()=>{this.loadRawImages(this.contentElLoader.contentEl)},100));this.spec=n.spec,this.isIOS=n.isIOS,this.submitAsyncImgsThrottled=tn(a=>{this.submitAsyncImgs(),a==null||a()},50);const o=new MutationObserver(this.reloadRawImages),i=(s=this.spec)!=null&&s.imgDivs?void 0:(()=>{let a=window.innerWidth;return new ResizeObserver(mt(()=>{const u=window.innerWidth;if(u!==a){a=u;return}this.reloadRawImages()},50))})();this.disconnectObservers=async()=>{o.disconnect(),i==null||i.disconnect()};let r=!1;this.contentElLoader=new ym((l=this.spec)==null?void 0:l.content,a=>{o.disconnect(),i==null||i.disconnect(),o.observe(a,{childList:!0,subtree:!0}),i==null||i.observe(a),r?this.reloadRawImages():(r=!0,this.loadRawImages(a))}),this.loadContentEl()}dispose(n){var o;this.isDisposed=!0,(o=this.disconnectObservers)==null||o.call(this),this.disconnectObservers=void 0,this.contentElLoader.dispose(),this.loadRawImagesThread.dispose(),this.imgLoadOnceObserver.dispose(),this.autoDownloadQueue.dispose(),this.canvasObserver.dispose(),this.imgSrcObserver.dispose(),n!==void 0&&this.scroller.scrollTo({rawImages:this.validRawImages,page:n,fallbackScrollEl:document.documentElement,isScrollExact:!0}),this.scroller.dispose()}onPageIndexChanged(n,o){this.currentPageIndex=o,this.scroller.scrollTo({rawImages:this.validRawImages,page:o,isScrollDown:!this.isScrolledOnce||n===void 0||o>n||this.validRawImages.length===1,fallbackScrollEl:this.isIOS?document.body:document.documentElement}),this.isScrolledOnce=!0,this.autoDownloadQueue.run({activeIndex:this.currentPageIndex})}onRawImagesLoaded(n){var o,i,r;if(this.rawImages=n,!this.isRawImagesLoadedOnce){this.isRawImagesLoadedOnce=!0;const s=this.initialPage!==void 0?Math.min(n.length-1,this.initialPage):Pm(n);if(this.currentPageIndex=Math.floor(s),this.initialPage!==s&&this.onInitialPageChanged(s),(o=this.spec)!=null&&o.imgDivs){const l=this.currentPageIndex>0&&!((i=n[this.currentPageIndex-1])!=null&&i.el),a=(r=n[this.currentPageIndex])==null?void 0:r.el;(l||!a)&&this.scroller.scrollTo({rawImages:n,page:l?s-1:s,isScrollDown:!0,skipIfVisible:!0,fallbackScrollEl:this.isIOS?document.body:document.documentElement})}}this.submitAsyncImgsThrottled(()=>{this.currentPageIndex!==void 0&&this.autoDownloadQueue.run({activeIndex:this.currentPageIndex,items:this.validRawImages})})}submitAsyncImgs(){const n=[],o=[];this.rawImages.forEach(i=>{let r=i.el?this.asyncImgsMap.get(i.el):void 0;!r&&i.parentEl&&(r=this.asyncImgsMap.get(i.parentEl)),(r||i.parentEl||i.el&&!this.asyncImgsMap.has(i.el))&&(n.push(r),o.push(i))}),this.validRawImages=o,this.onAsyncImgsChanged(n)}onImageElDownloaded(n,o,i){this.asyncImgsMap.set(n,i),o&&this.asyncImgsMap.set(o,i),this.submitAsyncImgsThrottled()}async downloadImageEl({el:n,parentEl:o}){if(n instanceof HTMLCanvasElement){this.canvasObserver.observe({el:n,parentEl:o});const r=await kr(n);if(!r||this.isDisposed)return;this.onImageElDownloaded(n,o,r);return}this.imgSrcObserver.observe({el:n,parentEl:o});const i=Sm(n);for(let r=0;r<i.length;r++){const s=i[r],l=await Ba({el:n,src:s,onSize:a=>{this.onImageElDownloaded(n,o,a)}});if(l!=null&&l.size)break;l!=null&&l.hasError&&r===i.length-1&&this.onImageElDownloaded(n,o,l)}}setRawImages(n){let o=!1;const i=n.map((r,s)=>{const l=this.rawImages[s];return l&&l.parentEl===r.parentEl&&(l.el===r.el||l.parentEl&&l.el&&!r.el)?l:(o=!0,r)});(o||i.length!==this.rawImages.length)&&this.onRawImagesLoaded(i)}async loadContentEl(){const n=await La(this.spec);this.isDisposed||this.contentElLoader.load(n)}async loadRawImages(n){this.isDisposed||!n.isConnected||await this.loadRawImagesThread.run(async o=>{var s;const i=(s=this.spec)==null?void 0:s.imgDivs,r=i?this.loadFromImgDivs(n,i):this.loadFromContentEl(n);o()||this.isDisposed||!n.isConnected||this.setRawImages(r)})}loadFromImgDivs(n,o){const i=hm(o,n);return i.length?i.map(s=>{const l=Cr(s).find(a=>this.validateImageEl(a,s));return{parentEl:s,el:l}}):this.loadFromContentEl(n)}loadFromContentEl(n){const o=[];return Cr(n).forEach(r=>{this.validateImageEl(r,n)&&o.push({el:r})}),o}validateImageEl(n,o){const i=Mn(n,o);return n instanceof HTMLImageElement?!i||!Tm(n)?(this.imgLoadOnceObserver.observe({el:n}),!1):!0:i&&Cm(n)}}function Cm(e){return e.isConnected&&mn(e.width,e.height)}function Tm(e){if(!e.isConnected)return!1;const t=e.getBoundingClientRect();return!t.width&&!e.naturalWidth||!t.height&&!e.naturalHeight||mn(t.width,t.height)}function Pm(e){var t,n;for(let o=0;o<e.length;o++){const i=((t=e[o])==null?void 0:t.el)??((n=e[o])==null?void 0:n.parentEl),r=i==null?void 0:i.getBoundingClientRect();if(!r||r.bottom<=0)continue;const s=r.top;return o+(s>=0?0:-s/r.height)}return 0}class Im extends Tr{constructor(n){super(n);ie(this,"srcs");ie(this,"queue");ie(this,"isDisposed",!1);this.srcs=n.srcs;const o=n.initialPage!==void 0?Math.min(n.srcs.length-1,n.initialPage):this.getInitialPage();n.initialPage!==o&&this.onInitialPageChanged(o);const i=new Map,r=tn(()=>{if(!this.isDisposed){const s=[];n.srcs.forEach(l=>{const a=i.get(l);(a||!i.has(l))&&s.push(a)}),this.onAsyncImgsChanged(s)}},50);r(),this.queue=new Na({download:async s=>Aa({src:s,onSize:l=>{i.set(s,l),r()}}).then(l=>{l!=null&&l.size||(i.set(s,l),r())})}),this.queue.run({items:n.srcs,activeIndex:Math.floor(o)})}dispose(n){this.isDisposed=!0,this.queue.dispose(),n!==void 0&&this.restoreScroll(n)}onPageIndexChanged(n,o){this.queue.run({items:this.srcs,activeIndex:o})}restoreScroll(n){const o=this.srcs[Math.min(this.srcs.length-1,Math.floor(n))];if(!o)return;const i=this.findImgElBySrc(o);if(!i)return;const r=Va(i,document.documentElement);if(!r)return;const{el:s,top:l}=r,a=n>=this.srcs.length?i.height:n%1*i.height;s.scrollTo({top:l+a,behavior:"instant"})}getInitialPage(){for(let n=0;n<this.srcs.length;n++){const o=this.findImgElBySrc(this.srcs[n]);if(!o)continue;const i=o==null?void 0:o.getBoundingClientRect();if(!i||i.bottom<=0)continue;const r=i.top;return n+(r>=0?0:-r/i.height)}return 0}findImgElBySrc(n){return document.querySelector(`img[src="${n}"],img[data-src="${n}"]`)}}function Em(e){var y,$,k,B;const t=(y=e.raw.value)==null?void 0:y.isWebtoon,n=ee(t),o=((k=($=e.raw.value)==null?void 0:$.imgs)==null?void 0:k.filter(Boolean))??[],i=ee([]);let r=e.isAutoShow!==!1&&e.page.value?e.page.value:void 0,s=!1,l=!1,a,u=setTimeout(e.onTimeout,2e4);const c=()=>{u&&(clearTimeout(u),u=void 0)},d=o.length?new Im({srcs:o,initialPage:r,onInitialPageChanged:f,onAsyncImgsChanged:p}):(B=e.spec)!=null&&B.paging?new fm({spec:e.spec,contentSel:e.spec.content,pagingSpec:e.spec.paging,initialPage:r,onAsyncImgsChanged:p,onInitialPageChanged:f,onError:()=>e.onError("SPEC_ERR")}):new km({isIOS:e.touchDevice&&!navigator.userAgent.toLowerCase().includes("android"),spec:e.spec,initialPage:r,onInitialPageChanged:f,onAsyncImgsChanged:p});function f(F){r=F}function p(F){if(i.value=F,r&&r>F.length&&(r=F.length-1),n.value!==void 0){b();return}let C=0,g=!1,T=0,x=0,z=0;const w=F.length<3?F:F.slice(F.length<5?1:2,-1),M=Math.min(2,w.length);for(let W=0;W<w.length;W++){const A=w[W];if(!A)continue;z++;const{size:X,hasError:I}=A;if(I){g||C++;continue}if(!X)continue;g=!0,C=0,a&&(a=void 0,clearTimeout(a));const ne=X.width/X.height;ne>2&&T++;const G=ne<.5||T>=M,P=!G&&.65<ne&&ne<.75;if(P&&x++,G&&n.value!==G&&(n.value=G),n.value===void 0&&P&&x>=M&&(n.value=!1),n.value===void 0&&z>=M&&(n.value=!1),n.value!==void 0){b();return}}C>1&&!a&&(a=setTimeout(()=>{a=void 0,n.value===void 0&&!l&&e.onTimeout()},7e3))}Mi(()=>{l=!0,d.dispose(s?e.page.value:void 0),a&&clearTimeout(a)});function b(){if(s||n.value===void 0||r===void 0)return;const F=Math.max(0,Math.min(r,i.value.length)),C=Math.min(Math.floor(F),i.value.length-1);!i.value[C]||C>0&&!i.value[C-1]||s||(s=!0,c(),e.onReady(F),fe(()=>Math.floor(e.page.value),(g,T)=>{g!==T&&d.onPageIndexChanged(T,g)},{immediate:!0}))}return{asyncImgs:Q(()=>i.value),isWebtoon:Q(()=>n.value??!1)}}function Ra({touchDevice:e,isBusy:t,isPlaying:n,isIdle:o,hideControlsEvent:i,scrollEl:r,moveThreshold:s}){const l=ee(!0);let a=!1,u=!1;const c={x:0,y:0};let d;Et(()=>{d==null||d(),d=void 0});function f(k){if(i.value===on.never||t.value&&l.value)return;const B=typeof k=="boolean"?k:!l.value;B!==l.value&&(l.value=B,!a&&!B&&(a=!0))}function p(){r.value&&(c.x=r.value.scrollLeft,c.y=r.value.scrollTop)}function b(){const k=i.value===on.firstMove,B=r.value;if(!B)return;const F=tn(()=>{if(!l.value){Mm(B)&&f(!0);return}if(k&&a)return;const C=Math.abs(B.scrollTop-c.y)||Math.abs(B.scrollLeft-c.x),g=s??(k?c.y===0?300:200:150);C>g&&f(!1)},100);B.addEventListener("scroll",F),d=()=>{B.removeEventListener("scroll",F)}}function y(){switch(d==null||d(),d=void 0,i.value){case on.onLoad:a||f(!1);break;case on.firstMove:b();break;case on.move:b();break;case on.never:l.value||(l.value=!0);break}}function $(){u||(u=!0,p(),y(),e&&fe(Gi(),B=>{B==="hidden"&&!n.value&&!l.value&&f(!0)}),fe(t,k=>{k&&!l.value&&f()}),fe(n,k=>{k||f(!0)}),fe(o,k=>{n.value&&f(!k)}),fe(l,k=>{k&&p()}),fe(i,()=>y()),fe(r,()=>y()))}return{visible:Q(()=>l.value),toggle:f,activate:$}}function Mm(e){const t=Math.max(0,e.scrollTop),n=Math.abs(e.scrollLeft);if(n<10&&t<10)return!0;const{scrollHeight:o,clientHeight:i}=e;if(o>i)return t>o-i-10;const{scrollWidth:s,clientWidth:l}=e;return s>l&&n>s-l-10}function Om(e,t,n){return Q(()=>t.value?Ha(e.value,n.value):e.value.map((o,i)=>[{img:o,index:i}]))}function Ha(e,t,n=0){if(e.length===0)return[];const o=e.slice(0,2),i=o.some(s=>(s==null?void 0:s.size)&&s.size.width>s.size.height),r=i||t?[o[0]]:o;return[r.map((s,l)=>({img:s,index:n+l})),...Ha(e.slice(r.length),t&&i,n+r.length)]}const Ir=40;function $m({page:e,asyncImgs:t,direction:n,style:o,isLongStrip:i,isVertical:r,isRTL:s,spaceTop:l,scrollEl:a,isWebtoon:u,interferePlayer:c,onChangedPage:d,onFinished:f}){let p=!1,b=!1,y,$=!1,k,B;const F=mt(M,300),C=tn(()=>{M(),F()},300);function g(){const _=new Promise(Y=>{y=()=>{y=void 0,Y()}});return z(e.value,{smooth:!1,ensureLastImgVisibility:!0}),_}function T(){var _;b=!0,y==null||y(),W(),(_=a.value)==null||_.addEventListener("scroll",C),setTimeout(()=>{const{width:Y,height:se}=vn();fe(()=>`${se.value}-${Y.value}`,x),fe(o,x),fe(n,x),fe(()=>t.value,(K,R)=>{!R||K.length===R.length||s.value&&x()})},300)}function x(){const _=a.value;if(!_)return;const Y=Date.now();B=Y;const{scrollWidth:se,scrollHeight:K}=_,R=e.value,Pe=Math.floor(R),ye=t.value[Pe];gt(20,10,async()=>{if(B!==Y)return!0;if(_.scrollWidth===se&&_.scrollHeight===K)return;let pe=R;if(ye){const ve=t.value.findIndex(xe=>xe===ye||(xe==null?void 0:xe.src)===ye.src);ve!==-1&&Pe!==ve&&(pe=ve+R-Pe)}return await z(pe),!0})}async function z(_,{smooth:Y,ensureLastImgVisibility:se=!1}={smooth:!1}){return new Promise(K=>{const R=a.value;if(!R){K();return}p=!0;const Pe=async()=>{await pt(),p=!1,b||T(),K()},ye=Math.floor(_),pe=wr(R,ye);if(!pe){Pe();return}c(async()=>{await w(R,!i.value&&Y,async()=>{await P(R,pe,{smooth:Y,page:_,ensureLastImgVisibility:se})}),await Pe()})})}async function w(_,Y,se){Y&&_.style.setProperty("scroll-snap-type","none"),await se(),Y&&_.style.removeProperty("scroll-snap-type")}function M(){if(p)return;const _=X();_!==void 0&&_!==e.value&&d(_),W()}function W(){$||!$&&A()&&($=!0,f())}function A(){const _=a.value;if(!_)return!1;const Y=!i.value||u.value?3:!r.value&&_.clientWidth>_.clientHeight?2.25:2.5;return r.value?_.scrollHeight-_.scrollTop<_.clientHeight*Y:_.scrollWidth-(s.value?-_.scrollLeft:_.scrollLeft)<_.clientWidth*Y}function X(){const _=I();return _?(+_.getAttribute("data-index")||0)+(i.value?ne(_):0):void 0}function I(){var Y;if(k??(k=a.value.getRootNode()),!k)return;const _=(Y=k.elementsFromPoint)==null?void 0:Y.call(k,r.value||!i.value?window.innerWidth/2:s.value?window.innerWidth-Ir:Ir,r.value&&i.value?l.value||Ir:window.innerHeight/2);if(_)for(let se=0;se<_.length;se++){const K=_[se];if(K.hasAttribute("data-index"))return K;if(K===a.value)break}}function ne(_){const Y=_.getBoundingClientRect();return r.value?Math.abs(Y.top-l.value)/Y.height:s.value?Math.max(0,Y.right-a.value.clientWidth)/Y.width:Math.abs(Y.left)/Y.width}let G=!1;async function P(_,Y,se){if(G)return;const K=Y.getBoundingClientRect();if(!i.value){if(r.value){if(K.top<=0&&K.bottom>=_.clientHeight)return}else if(K.left<=0&&K.right>=_.clientWidth)return}G=!0;const R=r.value?_.scrollTop:_.scrollLeft,Pe=se.page,ye=i.value?Pe%1:0,pe=await gt(30,10,async()=>{await wn();let Ae;if(!(Y.offsetHeight<10))return i.value?r.value?Ae=Y.offsetTop+ye*Y.offsetHeight-l.value:s.value?Ae=Y.offsetLeft-_.clientWidth+Y.offsetWidth-ye*Y.offsetWidth:Ae=Y.offsetLeft+ye*Y.offsetWidth:r.value?Ae=Y.offsetTop+(K.top>0?0:K.height-_.clientHeight):Ae=Y.offsetLeft+(K.left>0?0:K.width-_.clientWidth),Pe>.5&&Math.abs(Ae)<100?void 0:Ae})??0,ve=se.ensureLastImgVisibility?r.value?Math.min(pe,_.scrollHeight-_.clientHeight*2):s.value?Math.max(pe,-(_.scrollWidth-_.clientWidth*2)):Math.min(pe,_.scrollWidth-_.clientWidth*2):pe;if(!se.smooth){r.value?_.scrollTop=ve:_.scrollLeft=ve,G=!1;return}const xe=ve-R,Be=30;let Qe=0;return new Promise(Ae=>{(function $n(){const h=Dm(Qe,R,xe,Be);r.value?_.scrollTop=h:_.scrollLeft=h,Qe++,Qe<=Be?requestAnimationFrame($n):(Ae(),G=!1)})()})}return{init:g,goToPage:z}}function Dm(e,t,n,o){return n*(Math.pow(e/o-1,3)+1)+t}class zm{constructor(t){ie(this,"player");ie(this,"debounceStartPlayer");ie(this,"isPlaying");ie(this,"isIdle",ee(!1));ie(this,"onIdle");this.player=t.player,this.debounceStartPlayer=mt(()=>this.player.start(),100);const n=ee(t.autoPlay||sessionStorage.getItem("mp:playing")==="true");this.isPlaying=Q({get:()=>n.value,set:o=>{n.value=o,sessionStorage.setItem("mp:playing",o?"true":"false")}}),this.onIdle=mt(()=>{this.isIdle.value=!0},t.touchDevice?2e3:1e3),this.awake(),t.touchDevice||St(window,"mousemove",()=>this.awake()),je(()=>{t.touchDevice||fe(Gi(),i=>{this.isPlaying.value&&(i==="visible"?this.player.start():this.player.stop())}),fe(t.speed,()=>this.interfere()),fe(t.isBusy,o=>{!o&&this.isIdle.value&&this.awake()})}),Et(()=>this.stop())}activate(){this.isPlaying.value&&this.player.start()}toggle(){this.isPlaying.value?this.stop():this.start()}async interfere(t){this.isPlaying.value&&this.player.stop(),t&&(await pt(),await t()),this.isPlaying.value&&this.debounceStartPlayer()}stop(){this.isPlaying.value&&(this.isPlaying.value=!1,this.player.stop(),this.awake())}start(){this.isPlaying.value||(this.isPlaying.value=!0,this.player.start(),this.awake())}pause(){this.player.stop()}resume(){this.player.start()}awake(){setTimeout(()=>{this.isIdle.value=!1,this.onIdle()},30)}}class Fa extends zm{getMaxOffset(t){return t.scrollHeight-t.clientHeight}getScrollOffset(t){return t.scrollTop}setScrollOffset(t,n){t.scrollTop+=n}constructor(t){let n,o;const{scrollEl:i,speed:r}=t;super({...t,player:{stop:()=>o==null?void 0:o(),start:()=>{const s=i.value;if(!this.isPlaying.value||!s)return;const l=this.getMaxOffset(s),a=this.getScrollOffset(s);if(l<=a){this.stop();return}o=()=>{n=Date.now(),o=void 0};const u=Date.now();n=u;const c=.1*r.value;let d=Date.now(),f=0;const p=()=>{if(n!==u)return;const b=Date.now(),y=b-d;d=b;const $=c*y+f;$>=1?(f=$%1,this.setScrollOffset(s,$-f)):f=$,setTimeout(p,1)};p()}}})}}class Am extends Fa{constructor(n){super(n);ie(this,"isLongStrip");ie(this,"isVertical");ie(this,"isRTL");const{isLongStrip:o,isVertical:i,isRTL:r}=n;this.isLongStrip=o,this.isVertical=i,this.isRTL=r,o!==void 0&&je(()=>{fe(o,s=>{s||stop()})})}getMaxOffset(n){return this.isVertical.value?n.scrollHeight-n.clientHeight:n.scrollWidth-n.clientWidth}getScrollOffset(n){return this.isVertical.value?n.scrollTop:this.isRTL.value?-n.scrollLeft:n.scrollLeft}setScrollOffset(n,o){n[this.isVertical.value?"scrollTop":"scrollLeft"]+=o*(this.isRTL.value?-1:1)}start(){var n;((n=this.isLongStrip)==null?void 0:n.value)!==!1&&super.start()}}function Bm(e){return new Am(e)}function Lm({speed:e,fontSize:t,lineHeight:n,...o}){const i=vn().width;return new Fa({...o,speed:Q(()=>{const r=900/Math.min(900,i.value)/3.5,s=t.value/48*1.75,l=n.value/96*1.75,a=r*s*l;return e.value*a})})}const jm={key:3,class:"fixed inline-block left-1/2 -translate-x-1/2 bottom-0 p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3"},Wa=ge({inheritAttrs:!1,__name:"GearSecond",props:{chapterNavData:{type:Object},busy:{type:Boolean},defaultPreferences:{type:Object},immediate:{type:Boolean},appVersion:{type:String},raw:{type:Object},spec:{type:Object},siteMeta:{type:null},page:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},entryId:{type:String},isAutoShow:{type:Boolean},tourEnabled:{type:Boolean},offlineMode:{type:Boolean}},emits:["clickEntryButton","hideReader","openHelpScreen","error","crash","timeout","ready","pageChanged","playingChanged","dispose","openEntry","addEntry","finished","getHiddenChapters","hapticFeedback","pressedBack","selectChapter","openDefaultPreferences","defaultPreferencesChanged","controlsVisibilityChanged"],setup(e,{emit:t}){var N,H;const n=e,o=t,i=ee(!1),r=ee(!1),s=Q(()=>n.busy),l=Q(()=>n.page),a=Q(()=>n.immediate||i.value?n.spaceTop??0:0),u=Q(()=>!n.touchDevice&&I.isIdle.value&&!n.busy&&!T.value),{asyncImgs:c,isWebtoon:d}=Em({raw:Q(()=>n.raw),spec:n.spec,page:l,touchDevice:n.touchDevice,isAutoShow:n.isAutoShow,async onReady(O){Pe(O),i.value=!0},onError:()=>o("error"),onTimeout:()=>o("timeout")}),{direction:f,style:p,isRTL:b,isDouble:y,isVertical:$,isLongStrip:k,gap:B,speed:F,zoom:C,breakFirst:g}=Dh({touchDevice:n.touchDevice,isWebtoon:d,titleName:(N=n.raw)==null?void 0:N.title.name,defaultPreferences:Q(()=>n.defaultPreferences)}),T=ee(!1),x=Om(c,y,g),z=Q(()=>c.value.length),w=Q(()=>l.value>=z.value),M=ee(null),W=ee(null),A=Q(()=>{var O;return(O=W.value)==null?void 0:O.rootEl}),X=ee(!1),I=Bm({autoPlay:!n.tourEnabled&&(((H=n.defaultPreferences)==null?void 0:H.autoPlay)??!1),touchDevice:n.touchDevice,scrollEl:A,speed:F,isRTL:b,isVertical:$,isLongStrip:k,isBusy:s}),ne=Q({get(){return C.value},set(O){I.interfere(()=>{C.value=O})}}),G=Ra({touchDevice:n.touchDevice,isBusy:s,isPlaying:Q(()=>I.isPlaying.value),isIdle:Q(()=>I.isIdle.value),hideControlsEvent:Q(()=>n.defaultPreferences.hideControlsEvent),scrollEl:A}),P=G.visible,_=$m({page:l,asyncImgs:c,style:p,direction:f,isLongStrip:k,isVertical:$,isRTL:b,spaceTop:a,isWebtoon:d,scrollEl:Q(()=>{var O;return(O=W.value)==null?void 0:O.rootEl}),interferePlayer:O=>I.interfere(O),onChangedPage:Pe,onFinished:()=>o("finished")}),Y=Q(()=>Math.floor(l.value)),se=Q(()=>k.value?l.value:y.value?$n():Math.floor(l.value)),K=()=>I.interfere(()=>wn(100));Dt({onKeyDown:O=>{if(n.tourEnabled)return!0;const S=k.value&&$.value,V=k.value&&!$.value,L=!k.value&&$.value,ce=!k.value&&!$.value;switch(O.key){case" ":O.preventDefault(),k.value||h();break;case"ArrowUp":case"PageUp":S?K():L&&Y.value!==0&&(O.preventDefault(),Qe());break;case"ArrowDown":case"PageDown":S?K():L&&!w.value&&(O.preventDefault(),Ae());break;case"ArrowLeft":V?K():ce?(O.preventDefault(),xe()):$.value&&ve();break;case"ArrowRight":V?K():ce?(O.preventDefault(),Be()):$.value&&pe();break}},onKeyUp:O=>{switch(O.key){case"b":g.value=!g.value;break}}}),fe(I.isPlaying,O=>{o("playingChanged",O)}),fe(P,O=>{o("controlsVisibilityChanged",O)});async function R(){await _.init(),o("ready"),r.value=!0,G.activate(),I.activate()}function Pe(O){if(l.value===O)return;const S=c.value.length;if(O<0||O>=S+1)return;const V=l.value;if(o("pageChanged",O),O<.01&&V>O){I.awake();return}}function ye(){!n.touchDevice&&!k.value&&_.goToPage(Y.value,{smooth:!0})}function pe(O=!1){var S,V;(V=(S=n.chapterNavData)==null?void 0:S.next)==null||V.call(S,O)}function ve(O=!1){var S,V;(V=(S=n.chapterNavData)==null?void 0:S.prev)==null||V.call(S,O)}function xe(){b.value?Ae():Qe()}function Be(){b.value?Qe():Ae()}function Qe(){var V;const O=x.value,S=w.value?O[O.length-1][0].index:(V=O[$n()-1])==null?void 0:V[0].index;S!==void 0?_.goToPage(S):ve()}function Ae(){var O,S;if(w.value)pe();else{const V=((S=(O=x.value[$n()+1])==null?void 0:O[0])==null?void 0:S.index)??c.value.length;_.goToPage(V)}}function $n(){const O=Y.value,S=x.value.findIndex(V=>V.some(({index:L})=>L===O));return S===-1?x.value.length-1:S}function h(O){G.toggle(O)}function m(){if(I.isPlaying.value){P.value||!n.touchDevice?I.stop():(I.awake(),G.toggle(!0));return}G.toggle()}function E(){I.stop(),o("clickEntryButton")}function q(){G.toggle(!1),I.isPlaying.value&&I.stop(),o("openHelpScreen")}return(O,S)=>e.immediate||i.value?(v(),re(mr,{key:0,ref_key:"gearLayout",ref:M,loading:!r.value,immediate:!!e.immediate,"hide-cursor":u.value,class:"text-stone-100",onClick:S[21]||(S[21]=Ne(()=>{},["stop"]))},{default:oe(()=>{var V,L,ce,te;return[i.value?(v(),re(_a,{key:0,ref_key:"body",ref:W,zoom:ne.value,"onUpdate:zoom":S[1]||(S[1]=J=>ne.value=J),zooming:T.value,"onUpdate:zooming":S[2]||(S[2]=J=>T.value=J),page:l.value,"page-index":Y.value,pages:Z(x),"total-imgs":Z(c).length,direction:Z(f),gap:Z(B),"is-long-strip":Z(k),isRTL:Z(b),"is-double":Z(y),"is-vertical":Z($),"space-top":a.value||0,busy:s.value,"play-controller":Z(I),"touch-device":e.touchDevice,"pinch-to-zoome":((V=e.defaultPreferences)==null?void 0:V.pinchToZoom)??!0,"tap-zone":(L=e.defaultPreferences)==null?void 0:L.tapZone,"controls-visible":Z(P),onReady:R,onPrev:Qe,onNext:Ae,onClick:m,onDragEnd:ye,onWheelPassive:S[3]||(S[3]=()=>Z(I).interfere())},Oi({_:2},[i.value&&Z(c).length?{name:"end",fn:oe(()=>{var J,ue;return[j(er,{"has-next":!!((J=e.chapterNavData)!=null&&J.next),"offline-mode":!!e.offlineMode,seconds:((ue=e.defaultPreferences)==null?void 0:ue.autoNextSeconds)??5,"show-add-button":Z(C)===1&&!e.entryId&&!!e.raw&&!e.offlineMode,onNext:pe,onAddToLibrary:E,onHide:S[0]||(S[0]=()=>o("hideReader"))},null,8,["has-next","offline-mode","seconds","show-add-button"])]}),key:"0"}:void 0]),1032,["zoom","zooming","page","page-index","pages","total-imgs","direction","gap","is-long-strip","isRTL","is-double","is-vertical","space-top","busy","play-controller","touch-device","pinch-to-zoome","tap-zone","controls-visible"])):ae("",!0),j(xr,{modelValue:X.value,"onUpdate:modelValue":S[10]||(S[10]=J=>X.value=J),"enable-help":"",name:(ce=e.raw)==null?void 0:ce.title.name,"space-top":a.value,"enable-default-preferences":!e.touchDevice||!!e.appVersion,onHelp:q,onMore:S[11]||(S[11]=()=>o("openDefaultPreferences"))},{"tab-preferences":oe(()=>[j(ya,{"enable-reset":!e.touchDevice||!!e.appVersion,webtoon:Z(d),"reader-style":Z(p),"onUpdate:readerStyle":S[4]||(S[4]=J=>ze(p)?p.value=J:null),direction:Z(f),"onUpdate:direction":S[5]||(S[5]=J=>ze(f)?f.value=J:null),gap:Z(B),"onUpdate:gap":S[6]||(S[6]=J=>ze(B)?B.value=J:null),speed:Z(F),"onUpdate:speed":S[7]||(S[7]=J=>ze(F)?F.value=J:null),zoom:ne.value,"onUpdate:zoom":S[8]||(S[8]=J=>ne.value=J),"default-preferences":e.defaultPreferences},null,8,["enable-reset","webtoon","reader-style","direction","gap","speed","zoom","default-preferences"])]),"tab-default":oe(()=>[j(hr,{"model-value":e.defaultPreferences,"onUpdate:modelValue":S[9]||(S[9]=J=>o("defaultPreferencesChanged",J))},null,8,["model-value"])]),_:1},8,["modelValue","name","space-top","enable-default-preferences"]),r.value&&!w.value&&!e.tourEnabled?(v(),re(ga,{key:1,direction:Z(f),"tap-zone":(te=e.defaultPreferences)==null?void 0:te.tapZone},null,8,["direction","tap-zone"])):ae("",!0),r.value&&!w.value?(v(),re(vr,{key:2,playing:Z(I).isPlaying.value},null,8,["playing"])):ae("",!0),j(ma,{visible:Z(P),"space-top":a.value},Oi({top:oe(()=>{var J;return[e.raw||e.offlineMode?(v(),re(tr,{key:0,"offline-mode":e.offlineMode,raw:e.raw,onClick:S[12]||(S[12]=()=>o("pressedBack"))},null,8,["offline-mode","raw"])):ae("",!0),!e.touchDevice&&!e.offlineMode?(v(),re(Jo,{key:1,onClick:S[13]||(S[13]=()=>o("hideReader"))})):ae("",!0),e.chapterNavData?(v(),re(cr,{key:2,"touch-device":e.touchDevice,"chapter-spec":(J=e.spec)==null?void 0:J.chapter,data:e.chapterNavData,rtl:Z(b),onGetHiddenChapters:S[14]||(S[14]=()=>o("getHiddenChapters")),onPrev:ve,onNext:pe,onDialogOpened:S[15]||(S[15]=()=>Z(G).toggle(!1))},null,8,["touch-device","chapter-spec","data","rtl"])):ae("",!0)]}),"bottom-right":oe(()=>[!e.offlineMode&&e.raw?(v(),re(nr,{key:0,"entry-id":e.entryId,onClick:E},null,8,["entry-id"])):ae("",!0),j(sr,{disabled:!i.value,onClick:S[16]||(S[16]=()=>X.value=!0)},null,8,["disabled"]),e.touchDevice?ae("",!0):(v(),re(lr,{key:1,onRequestFullScreen:S[17]||(S[17]=()=>{var J,ue;return(ue=(J=M.value)==null?void 0:J.rootEl)==null?void 0:ue.requestFullscreen()})})),Z(k)?(v(),re(rr,{key:2,"tour-message":"Press here to play like a video",playing:Z(I).isPlaying.value,disabled:!r.value,onClick:S[18]||(S[18]=()=>Z(I).toggle())},null,8,["playing","disabled"])):ae("",!0),Z(y)?(v(),re(Je,{key:3,title:"Break 1st page (B)","data-tour":"Press here to separate the first page from double-page mode",disabled:!r.value,onClick:S[19]||(S[19]=()=>g.value=!Z(g))},{default:oe(()=>[Z(g)?(v(),re(ba,{key:0})):(v(),re(va,{key:1}))]),_:1},8,["disabled"])):ae("",!0)]),progress:oe(()=>{var J,ue;return[((J=e.defaultPreferences)==null?void 0:J.progressSize)!==0&&!w.value?(v(),re(br,{key:0,value:se.value,total:Z(x).length,"long-strip":Z(k),height:((ue=e.defaultPreferences)==null?void 0:ue.progressSize)??2,rtl:Z(b)},null,8,["value","total","long-strip","height","rtl"])):ae("",!0)]}),default:oe(()=>[e.appVersion&&a.value&&!e.offlineMode?(v(),D("div",{key:0,class:"fixed top-0 left-0 right-0 bg-black bg-opacity-70 pointer-events-auto",style:Te({height:`${a.value}px`})},null,4)):ae("",!0)]),_:2},[Z(x).length?{name:"bottom-left",fn:oe(()=>[j(wa,{"model-value":Y.value,disabled:!r.value,pages:Z(x),"total-imgs":Z(c).length,"onUpdate:modelValue":Z(_).goToPage},null,8,["model-value","disabled","pages","total-imgs","onUpdate:modelValue"])]),key:"0"}:void 0]),1032,["visible","space-top"]),Z(P)||T.value?(v(),D("div",jm,[j(to,{"enter-from-class":"opacity-0","leave-to-class":"opacity-0"},{default:oe(()=>[T.value||Z(C)!==1?(v(),re(Jl,{key:0,zoom:ne.value,onClick:S[20]||(S[20]=Ne(()=>ne.value=1,["stop"])),class:"duration-200"},null,8,["zoom"])):ae("",!0)]),_:1})])):ae("",!0),ke(O.$slots,"default")]}),_:3},8,["loading","immediate","hide-cursor"])):ae("",!0)}}),Nm=Object.freeze(Object.defineProperty({__proto__:null,default:Wa},Symbol.toStringTag,{value:"Module"}));function Vm({sel:e,heading:t,paraSel:n,useObfFont:o}){const i=["H1","H2","H3","H4","H5","H6","P","BLOCKQUOTE","PRE","CODE"],r=["BR","HR"],s=["BUTTON","FIGURE","IMG","SCRIPT","SELECT","INPUT","FORM","IFRAME","NAV","FOOTER","ASIDE","TABLE"],l=Rm(e),a=Hm(l),u=o?Fm(l):void 0,c=d(l);if(!c)return;return{el:c,isRTL:a,fontFamily:u};function d(b){var T;let y=0,$=!1,k=0,B=0,F=!1;const C=(T=g(b,i.includes(b.tagName)||!!n&&b.matches(n)))==null?void 0:T.node;if(!C)return;if(t){const x=document.createElement("h1");x.innerText=t,C.prepend(x)}return p(C),f(C),C;function g(x,z){var Y;if(F)return;if(x.nodeType===Node.TEXT_NODE)return z&&((Y=x.textContent)!=null&&Y.trim())?{node:x.cloneNode()}:void 0;if(x.nodeType!==Node.ELEMENT_NODE)return;const M=x.tagName;if(s.includes(M)||M==="A"&&($||!z))return;if(r.includes(M))return z?{node:document.createElement(M),isEmpty:!0}:{aborted:!0};if(x.getAttribute("aria-hidden")==="true"||!Mn(x)||window.getComputedStyle(x).position==="fixed")return;const A=!!n&&x.matches(n),X=A||i.includes(M),I=z||X,ne=[];if(Array.from(x.childNodes).forEach(se=>{if(F)return;const K=g(se,I);if(K!=null&&K.aborted)return;const R=K==null?void 0:K.node;if(R){if(B=K!=null&&K.isEmpty?B+1:0,B>2)return;ne.push(R),$?k=0:++y>30&&($=!0)}else $&&++k>30&&(F=!0)}),!ne.length)return X?{node:document.createElement("p"),isEmpty:!0}:void 0;const P=document.createElement(A?"p":M==="BODY"?"div":M==="a"?"span":M),_=x.getAttribute("dir");return _&&_!=="auto"&&P.setAttribute("dir",_),ne.forEach(se=>P.appendChild(se)),{node:P}}}function f(b){Ua(b,y=>{if(y===b)return;const $=y.tagName;if(r.includes($)||i.includes($))return;const k=y.parentElement;if((k==null?void 0:k.childNodes.length)===1){Array.from(y.childNodes).forEach(C=>{k.appendChild(C)}),k.removeChild(y);return}y.childNodes.length===1&&y.replaceWith(y.childNodes[0])})}function p(b){let y=!1;const $=[];Er(b,k=>i.includes(k.tagName)?[]:Array.from(k.children),k=>{const B=k.textContent.trim();if(!B)return!0;if(y)return!1;if(y=!qa(k),$.includes(B))return!0;if(y)return!1;$.push(B)}),Er(b,k=>i.includes(k.tagName)?[]:Array.from(k.children).reverse(),k=>!k.textContent.trim()||qa(k))}}function qa(e){const t=e.nodeName;return t.length===2&&t.startsWith("H")}function Rm(e){const t=(e??"main,article").split(",").filter(Boolean);for(const o of t){const i=document.querySelector(o);if(i)return i}const n=document.querySelector("p:has(+ p), h1, h2");if(n){let o=n;for(;o!==document.body;)o=o.parentElement;return o}return document.body}function Hm(e,t){if(e.getAttribute("dir")==="rtl")return!0;const n=e.querySelector("p")||e.querySelector("div:not(:empty)")||e;return n.getAttribute("dir")==="rtl"?!0:window.getComputedStyle(n).direction==="rtl"}function Fm(e,t){const n=e.querySelector("p")||e.querySelector("div:not(:empty)")||e;return window.getComputedStyle(n).fontFamily}function Ua(e,t){Array.from(e.children).forEach(o=>{Ua(o,t)}),t(e)}function Er(e,t,n){const o=t(e);let i=!1;for(let r=0;r<o.length;r++){const s=o[r],l=Er(s,t,n);if(l!==void 0){if(!l)return!1;Wm(s)}else i=!0}if(!i)return n(e)}function Wm(e){var t;(t=e.parentNode)==null||t.removeChild(e)}const qm={key:1,class:"h-14 sm:h-16 px-2 2xs:px-3 flex gap-1 2xs:gap-3 items-center"},Um={class:"md:fixed left-0 right-0 bottom-0"},Km={class:"p-2 2xs:px-3 sm:py-3 pb-6 md:pb-5 lg:pb-3 flex md:flex-col gap-4 justify-between items-center"},Ka=ge({__name:"GearThirdControlsLayout",props:{visible:{type:Boolean},hideTopControls:{type:Boolean},spaceTop:{type:null}},setup(e){return(t,n)=>(v(),D(we,null,[U("div",{class:de(["fixed left-0 right-0 top-0 bg-inherit z-30",{"opacity-0 pointer-events-none":!e.visible}])},[e.spaceTop?(v(),D("div",{key:0,style:Te({height:`${e.spaceTop}px`})},null,4)):ae("",!0),e.hideTopControls?ae("",!0):(v(),D("div",qm,[ke(t.$slots,"top-controls")]))],2),U("div",{class:de(["fixed left-0 right-0 bottom-0 md:left-auto z-30 bg-inherit md:bg-transparent",{"opacity-0 pointer-events-none":!e.visible}])},[U("div",Um,[ke(t.$slots,"progress")]),U("div",Km,[ke(t.$slots,"bottom-controls")])],2),ke(t.$slots,"default")],64))}}),Zm=Object.freeze(Object.defineProperty({__proto__:null,default:Ka},Symbol.toStringTag,{value:"Module"})),Ym={},Xm={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function Gm(e,t){return v(),D("svg",Xm,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M16 13q-.425 0-.712-.288T15 12t.288-.712T16 11h6q.425 0 .713.288T23 12t-.288.713T22 13zM4.675 15.425l-1.025 2.85q-.125.35-.4.538T2.625 19q-.575 0-.913-.487t-.137-1.038l4.4-11.725Q6.1 5.4 6.4 5.2t.65-.2h.9q.375 0 .663.2t.412.55L13.45 17.5q.2.55-.137 1.025T12.4 19q-.35 0-.65-.2t-.425-.55l-1-2.825zM5.4 13.4h4.2L7.55 7.6h-.1z"},null,-1)])])}const Za=be(Ym,[["render",Gm]]),Jm=Object.freeze(Object.defineProperty({__proto__:null,default:Za},Symbol.toStringTag,{value:"Module"})),Qm={},e0={xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 24 24"};function t0(e,t){return v(),D("svg",e0,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"m4.675 15.425l-1.025 2.85q-.125.35-.4.538T2.625 19q-.575 0-.913-.487t-.137-1.038l4.4-11.725Q6.1 5.4 6.4 5.2t.65-.2h.9q.375 0 .663.2t.412.55L13.45 17.5q.2.55-.137 1.025T12.4 19q-.35 0-.65-.2t-.425-.55l-1-2.825zM5.4 13.4h4.2L7.55 7.6h-.1zM18 13h-2q-.425 0-.712-.288T15 12t.288-.712T16 11h2V9q0-.425.288-.712T19 8t.713.288T20 9v2h2q.425 0 .713.288T23 12t-.288.713T22 13h-2v2q0 .425-.288.713T19 16t-.712-.288T18 15z"},null,-1)])])}const Ya=be(Qm,[["render",t0]]),n0=Object.freeze(Object.defineProperty({__proto__:null,default:Ya},Symbol.toStringTag,{value:"Module"})),Xa=be(ge({__name:"NovelBody",props:{hideTopControls:{type:Boolean},progress:{type:Number},touchDevice:{type:Boolean},busy:{type:Boolean},spaceTop:{type:null},content:{type:null},rtl:{type:Boolean},fontFamily:{type:String},titlePreferences:{type:Object},defaultPreferences:{type:Object}},emits:["ready","click","progressChanged","finished"],setup(e,{expose:t,emit:n}){const o=e,i=n,r=ee(!1),s=ee(),l=ee(),a=tn(()=>{const c=s.value;if(!c)return;const{clientHeight:d,scrollHeight:f,scrollTop:p}=c,b=Math.max(p,f-2*d);if(b<=0)i("progressChanged",1);else{const y=p/b;i("progressChanged",Math.max(0,Math.min(1,y)))}},30);t({scrollEl:s}),Dt({onKeyDown(){var c;o.busy||(c=s.value)==null||c.focus()}}),je(()=>{fe(()=>o.content,d=>{const f=l.value;f&&(Array.from(f.children).forEach(p=>{f.removeChild(p)}),f.appendChild(d),setTimeout(()=>{if(s.value){const{progress:b}=o;b&&u(b)}r.value=!0,i("ready")}))},{immediate:!0});const c=vn();fe(()=>{const{fontFamily:d,fontSize:f,lineHeight:p}=o.titlePreferences;return`${d}-${f}-${p}-${c.width.value}`},async()=>{const d=o.progress;await pt(),u(d)})});function u(c){const d=s.value;d&&(d.scrollTop=c*(d.scrollHeight-2*d.clientHeight))}return(c,d)=>(v(),D("div",{ref_key:"scrollContainer",ref:s,tabindex:"0",class:de(["novel-body",{"scrollbar-sm":!e.touchDevice,"scrollbar-none":e.touchDevice,"opacity-0":!r.value,"pt-16 sm:pt-18 md:pt-20":!e.hideTopControls,"pt-5 sm:pt-9 md:pt-12":e.hideTopControls}]),style:Te({fontFamily:e.fontFamily??e.titlePreferences.fontFamily,"--font-size":`${e.titlePreferences.fontSize}px`,"--line-height":`${e.titlePreferences.lineHeight}px`,"--space-top":e.spaceTop?`${e.spaceTop}px`:void 0}),onClick:d[0]||(d[0]=()=>i("click")),onScroll:d[1]||(d[1]=(...f)=>Z(a)&&Z(a)(...f))},[U("div",In({ref_key:"contentContainer",ref:l,class:"novel-body__content"},e.rtl?{dir:"rtl"}:{}),null,16),ke(c.$slots,"end")],38))}}),[["styles",['.novel-body{top:0;right:0;bottom:0;left:0;overflow-wrap:break-word;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;padding-left:32px;padding-right:32px;position:fixed}.novel-body:focus{outline:2px solid transparent;outline-offset:2px}@media (min-width:640px){.novel-body{padding-left:48px;padding-right:48px}}@media (min-width:768px){.novel-body{padding-left:56px;padding-right:56px}}@media (min-width:1024px){.novel-body{padding-left:64px;padding-right:64px}}@media (min-width:1280px){.novel-body{padding-left:80px;padding-right:80px}}.novel-body{font-size:var(--font-size);letter-spacing:.01em;line-height:var(--line-height)}.novel-body:before{content:"";display:block;height:var(--space-top,0)}.novel-body__content{margin-left:auto;margin-right:auto;max-width:768px;min-height:100%}.novel-body hr{--tw-border-opacity:1;border-color:rgb(87 83 78/var(--tw-border-opacity,1));margin:calc(var(--line-height)*.5) 0}.novel-body h1,.novel-body h2,.novel-body h3,.novel-body h4,.novel-body h5,.novel-body h6{font-weight:500}.novel-body h1{font-size:calc(var(--font-size)*1.5);line-height:calc(var(--font-size)*.5 + var(--line-height))}.novel-body h2{font-size:calc(var(--font-size)*1.25);line-height:calc(var(--font-size)*.25 + var(--line-height))}.novel-body h3{font-size:calc(var(--font-size)*1.125);line-height:calc(var(--font-size)*.125 + var(--line-height))}.novel-body h5,.novel-body h6,.novel-body p{font-size:inherit;line-height:inherit}.novel-body blockquote,.novel-body figure,.novel-body h1,.novel-body h2,.novel-body h3,.novel-body h4,.novel-body h5,.novel-body h6,.novel-body img,.novel-body ol,.novel-body p,.novel-body ul{margin-bottom:calc(var(--line-height)*.5)}.novel-body pre{background-color:transparent;border-style:none;display:block;font-family:inherit;margin:0;padding:0;white-space:normal}']]]),o0=Object.freeze(Object.defineProperty({__proto__:null,default:Xa},Symbol.toStringTag,{value:"Module"})),Ga=ge({inheritAttrs:!1,__name:"GearThird",props:{chapterNavData:{type:Object},busy:{type:Boolean},defaultPreferences:{type:Object},immediate:{type:Boolean},appVersion:{type:String},raw:{type:Object},spec:{type:Object},siteMeta:{type:null},page:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},entryId:{type:String},isAutoShow:{type:Boolean},tourEnabled:{type:Boolean},offlineMode:{type:Boolean}},emits:["clickEntryButton","hideReader","openHelpScreen","error","crash","timeout","ready","pageChanged","playingChanged","dispose","openEntry","addEntry","finished","getHiddenChapters","hapticFeedback","pressedBack","selectChapter","openDefaultPreferences","defaultPreferencesChanged","controlsVisibilityChanged"],setup(e,{emit:t}){var X,I,ne,G,P,_,Y,se;const n=e,o=t,i=ee(null),r=((X=n.raw)==null?void 0:X.novel)??Vm({sel:(I=n.spec)==null?void 0:I.content,heading:(ne=n.raw)==null?void 0:ne.name,paraSel:(G=n.spec)==null?void 0:G.para,useObfFont:!!((P=n.spec)!=null&&P.obfFont)});r===void 0&&o("error");const s=ee(r==null?void 0:r.el),l=!!(r!=null&&r.isRTL),a=ee(!1),u=ee(!1),c=Q(()=>n.page),d=Q(()=>n.busy),f=ee(null),p=Q(()=>{var K;return(K=f.value)==null?void 0:K.scrollEl}),b=(Y=(_=n.raw)==null?void 0:_.title)==null?void 0:Y.name,y=b?fa(b):location.hostname,$=gf(`mpr:${y}`,{}),k=Q({get(){var ye,pe;const K=n.defaultPreferences,R=((ye=$.value)==null?void 0:ye.fontSize)??K.fontSize,Pe=Math.max(R,((pe=$.value)==null?void 0:pe.lineHeight)??K.lineHeight);return{fontFamily:K.fontFamily,speed:K.speed,...$.value,contrast:K.contrast,fontSize:R,lineHeight:Pe}},set(K){const R={...K},Pe=n.defaultPreferences;Object.keys(R).forEach(ye=>{R[ye]===Pe[ye]&&delete R[ye]}),$.value=R}}),B=Lm({isBusy:d,speed:Q(()=>k.value.speed),fontSize:Q(()=>k.value.fontSize),lineHeight:Q(()=>k.value.lineHeight),autoPlay:!!((se=n.defaultPreferences)!=null&&se.autoPlay),touchDevice:n.touchDevice,scrollEl:p}),F=Q(()=>!n.touchDevice&&B.isIdle.value&&!d.value),C=Ra({touchDevice:n.touchDevice,moveThreshold:50,isBusy:d,isPlaying:Q(()=>B.isPlaying.value),isIdle:Q(()=>B.isIdle.value),hideControlsEvent:Q(()=>n.defaultPreferences.hideControlsEvent),scrollEl:p}),g=C.visible;fe(B.isPlaying,K=>{o("playingChanged",K)}),fe(g,K=>{o("controlsVisibilityChanged",K)}),T(document.documentElement),T(document.body);function T(K){const R=K.style.getPropertyValue("overflow");R!=="hidden"&&(K.style.setProperty("overflow","hidden","important"),Et(()=>{R?K.style.setProperty("overflow",R):K.style.removeProperty("overflow")}))}function x(){o("ready"),C.activate(),B.activate()}function z(){B.stop(),o("clickEntryButton")}function w(K){u.value=K}function M(){if(B.isPlaying.value){g.value||!n.touchDevice?B.stop():(B.awake(),C.toggle(!0));return}C.toggle()}function W(K){K!==n.page&&(o("pageChanged",Math.min(1,K)),K>=1&&o("finished"))}function A(K){const R=k.value.fontSize+K;R>48||R<10||(k.value={...k.value,fontSize:R,lineHeight:Math.max(10,Math.min(96,Math.round(k.value.lineHeight/k.value.fontSize*R)))})}return(K,R)=>s.value?(v(),re(mr,{key:0,ref_key:"gearLayout",ref:i,immediate:"","hide-cursor":F.value,class:"bg-stone-900",style:Te({color:`rgba(255, 255, 255, ${e.defaultPreferences.contrast})`})},{default:oe(()=>{var Pe,ye;return[j(Xa,{ref_key:"body",ref:f,progress:c.value,"touch-device":e.touchDevice,busy:d.value,"space-top":e.spaceTop,content:s.value,rtl:l,"font-family":(Pe=Z(r))==null?void 0:Pe.fontFamily,"title-preferences":k.value,"default-preferences":e.defaultPreferences,"hide-top-controls":!e.raw,onClick:M,onProgressChanged:W,onReady:x},{end:oe(()=>{var pe,ve;return[j(er,{"has-next":!!((pe=e.chapterNavData)!=null&&pe.next),"offline-mode":!!e.offlineMode,seconds:((ve=e.defaultPreferences)==null?void 0:ve.autoNextSeconds)??5,onNext:R[0]||(R[0]=()=>{var xe,Be;return(Be=(xe=e.chapterNavData)==null?void 0:xe.next)==null?void 0:Be.call(xe,!1)}),onVisibilityChanged:w,onHide:R[1]||(R[1]=()=>o("hideReader")),onFinished:R[2]||(R[2]=()=>o("finished"))},null,8,["has-next","offline-mode","seconds"])]}),_:1},8,["progress","touch-device","busy","space-top","content","font-family","title-preferences","default-preferences","hide-top-controls"]),!e.touchDevice&&!e.raw&&!e.offlineMode?He((v(),re(Jo,{key:0,class:"hidden md:inline-block fixed left-3 top-2",transparent:"",onClick:R[3]||(R[3]=()=>o("hideReader"))},null,512)),[[gd,Z(g)]]):ae("",!0),j(Ka,{visible:Z(g),"hide-top-controls":!e.raw,"space-top":e.spaceTop},{"top-controls":oe(()=>{var pe;return[e.raw||e.offlineMode?(v(),re(tr,{key:0,"offline-mode":e.offlineMode,raw:e.raw,transparent:"",onClick:R[4]||(R[4]=()=>o("pressedBack"))},null,8,["offline-mode","raw"])):ae("",!0),e.raw&&!e.touchDevice&&!e.offlineMode?(v(),re(Jo,{key:1,transparent:"",onClick:R[5]||(R[5]=()=>o("hideReader"))})):ae("",!0),e.chapterNavData?(v(),re(cr,{key:2,transparent:"","touch-device":e.touchDevice,"chapter-spec":(pe=e.spec)==null?void 0:pe.chapter,data:e.chapterNavData,rtl:l,onGetHiddenChapters:R[6]||(R[6]=()=>o("getHiddenChapters")),onPrev:R[7]||(R[7]=ve=>{var xe,Be;return(Be=(xe=e.chapterNavData)==null?void 0:xe.prev)==null?void 0:Be.call(xe,ve)}),onNext:R[8]||(R[8]=ve=>{var xe,Be;return(Be=(xe=e.chapterNavData)==null?void 0:xe.next)==null?void 0:Be.call(xe,ve)}),onDialogOpened:R[9]||(R[9]=()=>Z(C).toggle(!1))},null,8,["touch-device","chapter-spec","data"])):ae("",!0)]}),"bottom-controls":oe(()=>[!e.offlineMode&&e.raw?(v(),re(nr,{key:0,"entry-id":e.entryId,transparent:"",onClick:z},null,8,["entry-id"])):ae("",!0),j(Je,{transparent:"",onClick:R[10]||(R[10]=()=>A(-1))},{default:oe(()=>[j(Za)]),_:1}),j(Je,{transparent:"",onClick:R[11]||(R[11]=()=>A(1))},{default:oe(()=>[j(Ya)]),_:1}),j(sr,{transparent:"",onClick:R[12]||(R[12]=()=>a.value=!0)}),e.touchDevice?ae("",!0):(v(),re(lr,{key:1,transparent:"",onRequestFullScreen:R[13]||(R[13]=()=>{var pe,ve;return(ve=(pe=i.value)==null?void 0:pe.rootEl)==null?void 0:ve.requestFullscreen()})})),j(rr,{transparent:"","tour-message":"Press here to start listening",playing:Z(B).isPlaying.value,class:"order-2 md:order-4",onClick:R[14]||(R[14]=()=>Z(B).toggle())},null,8,["playing"])]),progress:oe(()=>{var pe,ve;return[((pe=e.defaultPreferences)==null?void 0:pe.progressSize)!==0?(v(),re(br,{key:0,value:c.value,height:((ve=e.defaultPreferences)==null?void 0:ve.progressSize)??2,rtl:l,opacity:e.defaultPreferences.contrast},null,8,["value","height","opacity"])):ae("",!0)]}),_:1},8,["visible","hide-top-controls","space-top"]),u.value?ae("",!0):(v(),re(vr,{key:1,playing:Z(B).isPlaying.value},null,8,["playing"])),j(xr,{modelValue:a.value,"onUpdate:modelValue":R[18]||(R[18]=pe=>a.value=pe),name:(ye=e.raw)==null?void 0:ye.title.name,"space-top":(e.spaceTop??0)+80,"enable-default-preferences":!e.touchDevice||!!e.appVersion,onMore:R[19]||(R[19]=()=>o("openDefaultPreferences"))},{"tab-preferences":oe(()=>{var pe;return[j(pr,{modelValue:k.value,"onUpdate:modelValue":R[15]||(R[15]=ve=>k.value=ve),"default-preferences":e.defaultPreferences,"enable-reset":!e.touchDevice||!!e.appVersion,"force-font-family":(pe=Z(r))==null?void 0:pe.fontFamily,onReset:R[16]||(R[16]=()=>$.value=null)},null,8,["modelValue","default-preferences","enable-reset","force-font-family"])]}),"tab-default":oe(()=>[j(hr,{"is-novel":"","model-value":e.defaultPreferences,"onUpdate:modelValue":R[17]||(R[17]=pe=>o("defaultPreferencesChanged",pe))},null,8,["model-value"])]),_:1},8,["modelValue","name","space-top","enable-default-preferences"]),ke(K.$slots,"default")]}),_:3},8,["hide-cursor","style"])):ae("",!0)}}),i0=Object.freeze(Object.defineProperty({__proto__:null,default:Ga},Symbol.toStringTag,{value:"Module"}));function r0({raw:e,spec:t,siteMeta:n,offlineMode:o,onSelect:i}){var W,A,X;const{vol:r,inferVol:s,chap:l,title:a,slug:u,basePath:c}=e,d=typeof(t==null?void 0:t.chapter)=="string"?{sel:t.chapter}:t==null?void 0:t.chapter;let f=-1;async function p(I,ne){if(o){i({...I});return}if(I.slug){b(I.slug,ne);return}if(I.elIndex===void 0||!(d!=null&&d.sel))return;let G=null;document.querySelector(d.sel)||(d!=null&&d.trigger&&(G=document.querySelector(d.trigger)),G&&(bn(G),await new Promise(_=>setTimeout(()=>_(),50))));const P=d&&d.sel&&!d.url?document.querySelectorAll(d.sel):void 0;P!=null&&P[I.elIndex]&&(bn(P[I.elIndex]),G&&document.querySelector(d.sel)&&bn(G))}function b(I,ne){const G=s0(c,I,(n==null?void 0:n.trailing)??!0);ne?window.open(G,"_blank","noopener"):location.href=G}function y(I){const ne=C[I];return ne?G=>p(ne,G):void 0}function $(I,ne,G){if(ne)b(ne,G);else if(I){const P=document.querySelector(I);P&&bn(P,{preventDefault:!1})}}const k=r??s,B=d==null?void 0:d.url,F=((W=a.chapters)==null?void 0:W.filter(I=>I.slug||!B&&I.elIndex!==void 0))??[],C=F.length>1?F:[],g=(A=e.prev)==null?void 0:A.slug,T=(X=e.next)==null?void 0:X.slug,x=t!=null&&t.prev&&typeof t.prev!="string"?t.prev.btn??t.prev.sel:void 0,z=t!=null&&t.next&&typeof t.next!="string"?t.next.btn??t.next.sel:void 0;let w=g||x&&!C.length&&document.body.querySelector(x)?I=>$(x,g,I):void 0,M=T||z&&!C.length&&document.body.querySelector(z)?I=>$(z,T,I):void 0;if(C.length){if(B&&(f=C.findIndex(I=>I.slug===e.slug)),f===-1&&(f=C.findIndex(I=>(I.vol??I.inferVol)===k&&I.chap===l)),B&&f===-1&&(f=C.findIndex(I=>I.slug&&u.startsWith(`${I.slug}-`)&&u.length-I.slug.length>3)),f!==-1)w??(w=y(f+1)),M??(M=y(f-1));else if(!g&&!T){const I=C.findIndex(ne=>{const G=ne.vol??ne.inferVol;return k===void 0||G===void 0||k===G?ne.chap<l:G<k});I!==-1?(w=y(I),M=y(I-1)):M=y(C.length-1)}}return{activeIndex:f,activeLabel:Ja({vol:r,chap:l}),prev:w,next:M,chapters:C.map(I=>({label:Ja(I),select:ne=>p(I,ne)}))}}function Ja({vol:e,chap:t}){return e==null?`Ch.${t}`:`Vol.${e} ch.${t}`}function s0(e,t,n){const o=!t||t.includes("//")||t.startsWith("/")?t:"/"+[...e.split("/"),...t.split("/")].filter(Boolean).join("/"),[i,r]=(o.includes("//")?o:location.origin+o).split("?");return[i.endsWith("/")===n?i:n?i+"/":i.substring(0,-1),r].filter(Boolean).join("?")}function l0(e){return e instanceof Error?JSON.stringify(e,Object.getOwnPropertyNames(e)):e}const Qa=be(ge({inheritAttrs:!1,__name:"App",props:{immediate:{type:Boolean},appVersion:{type:String},raw:{type:Object},spec:{type:Object},siteMeta:{type:null},page:{type:Number},spaceTop:{type:Number},touchDevice:{type:Boolean},entryId:{type:String},defaultPreferences:{type:Object},isAutoShow:{type:Boolean},tourEnabled:{type:Boolean},offlineMode:{type:Boolean}},emits:["error","crash","timeout","ready","pageChanged","playingChanged","dispose","openEntry","addEntry","finished","getHiddenChapters","hapticFeedback","pressedBack","selectChapter","openDefaultPreferences","defaultPreferencesChanged","controlsVisibilityChanged"],setup(e,{emit:t}){var T,x,z;const n=e,o=t;let i=!1,r=0;Cs((w,M,W)=>{if(!i){i=!0;const X=`(3.6.0) ${(M==null?void 0:M.$options.name)??(M==null?void 0:M.$options.__name)??(M==null?void 0:M.$options.__file)}.${W}: ${l0(w)}`;o("crash",X)}return!1});const s=ee(n.raw?n.raw.contentType??Zt.manga:void 0);s.value===void 0&&Hd(((T=n.spec)==null?void 0:T.content)??"body",{paraSel:(x=n.spec)==null?void 0:x.para,include:(z=n.siteMeta)==null?void 0:z.contentTypes,timeoutMs:3e3}).then(w=>{w?s.value=w:o("error")});const l=ee(!1),a=ee(n.tourEnabled),u=wf({touchDevice:n.touchDevice}),c=kf(n.page,n.isAutoShow),d=Q(()=>n.raw?r0({raw:n.raw,spec:n.spec,siteMeta:n.siteMeta,offlineMode:n.offlineMode,onSelect:w=>o("selectChapter",w)}):void 0);Sf().addListener({onKeyDown:w=>{switch(w.key){case"Escape":w.preventDefault();break}},onKeyUp:w=>{switch(w.key){case"h":C();break}}}),xf(()=>o("hapticFeedback"));const p=mt(w=>o("pageChanged",w),300),b=ee(y(n.defaultPreferences));fe(()=>n.defaultPreferences,w=>b.value=y(w));function y(w){const M=(w==null?void 0:w.fontSize)??16,W=Math.max(M,(w==null?void 0:w.lineHeight)??28);return{...w,speed:(w==null?void 0:w.speed)??1,progressSize:(w==null?void 0:w.progressSize)??2,autoNextSeconds:(w==null?void 0:w.autoNextSeconds)??5,hideControlsEvent:(w==null?void 0:w.hideControlsEvent)??on.firstMove,autoPlay:(w==null?void 0:w.autoPlay)??!1,pinchToZoom:(w==null?void 0:w.pinchToZoom)??!0,readerStyle:(w==null?void 0:w.readerStyle)??At.longStrip,direction:(w==null?void 0:w.direction)??nt.vertical,gap:(w==null?void 0:w.gap)??0,fontFamily:(w==null?void 0:w.fontFamily)??Qo[0].value,contrast:(w==null?void 0:w.contrast)??.8,fontSize:M,lineHeight:W}}function $(w){b.value=y(w),o("defaultPreferencesChanged",w)}function k(){if(n.offlineMode){o("pressedBack");return}Cf(),o("dispose")}function B(w){const M=Math.floor(w*100)/100;M!==Math.floor(c.value*100)/100&&(c.value=w,!(r>=M)&&(r=M,p(M)))}function F(){n.entryId?o("openEntry",n.entryId):o("addEntry")}function C(w){l.value!==w&&(l.value=w??!l.value)}function g(){o("error"),k()}return(w,M)=>s.value!==void 0?(v(),re(Ps(s.value===Z(Zt).novel?Ga:Wa),In({key:0,ref:"root"},n,{page:Z(c),busy:Z(u),"chapter-nav-data":d.value,"default-preferences":b.value,onOpenDefaultPreferences:M[1]||(M[1]=()=>o("openDefaultPreferences")),onTimeout:M[2]||(M[2]=()=>o("timeout")),onReady:M[3]||(M[3]=()=>o("ready")),onFinished:M[4]||(M[4]=()=>o("finished")),onPlayingChanged:M[5]||(M[5]=W=>o("playingChanged",W)),onControlsVisibilityChanged:M[6]||(M[6]=W=>o("controlsVisibilityChanged",W)),onPressedBack:M[7]||(M[7]=()=>o("pressedBack")),onGetHiddenChapters:M[8]||(M[8]=()=>o("getHiddenChapters")),onError:g,onHideReader:k,onPageChanged:B,onClickEntryButton:F,onDefaultPreferencesChanged:$,onOpenHelpScreen:M[9]||(M[9]=()=>C(!0))}),{default:oe(()=>[l.value?(v(),re(Wl,{key:0,"touch-device":e.touchDevice,onHide:C},null,8,["touch-device"])):ae("",!0),a.value?(v(),re(ql,{key:1,onHide:M[0]||(M[0]=()=>a.value=!1)})):ae("",!0)]),_:1},16,["page","busy","chapter-nav-data","default-preferences"])):ae("",!0)}}),[["styles",['*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*! tailwindcss v3.4.18 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:Helvetica,sans-serif;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-feature-settings:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]:where(:not([hidden=until-found])){display:none}*{-webkit-tap-highlight-color:rgba(0,0,0,0)!important}button{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-image:none;border-style:none;cursor:pointer;outline:2px solid transparent;outline-offset:2px;white-space:nowrap}button[disabled]{cursor:default!important}svg{height:100%}.container,svg{width:100%}@media (min-width:300px){.container{max-width:300px}}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.scrollbar-none{scrollbar-width:none}.scrollbar-none::-webkit-scrollbar{display:none}.scrollbar-sm{scrollbar-color:#777 transparent;scrollbar-width:thin}.scrollbar-sm::-webkit-scrollbar{background-color:transparent;height:4px;width:4px}.scrollbar-sm::-webkit-scrollbar-track{background:transparent}.scrollbar-sm::-webkit-scrollbar-thumb{background-color:#777;border-radius:2px}.\\!pointer-events-none{pointer-events:none!important}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.\\!visible{visibility:visible!important}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-0{bottom:0}.bottom-1{bottom:4px}.bottom-full{bottom:100%}.left-0{left:0}.left-1{left:4px}.left-1\\/2{left:50%}.left-10{left:40px}.left-3{left:12px}.left-9{left:36px}.right-0{right:0}.top-0{top:0}.top-1{top:4px}.top-1\\/2{top:50%}.top-10{top:40px}.top-2{top:8px}.top-9{top:36px}.top-full{top:100%}.-z-10{z-index:-10}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.order-2{order:2}.m-0{margin:0}.m-auto{margin:auto}.-mx-12{margin-left:-48px;margin-right:-48px}.-my-12{margin-bottom:-48px;margin-top:-48px}.-ml-20{margin-left:-80px}.-mr-3{margin-right:-12px}.-mt-2{margin-top:-8px}.mb-2{margin-bottom:8px}.mb-3{margin-bottom:12px}.mb-5{margin-bottom:20px}.ml-1{margin-left:4px}.ml-auto{margin-left:auto}.mt-5{margin-top:20px}.box-border{box-sizing:border-box}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.hidden{display:none}.\\!h-9{height:36px!important}.h-0{height:0}.h-1{height:4px}.h-1\\/3{height:33.333333%}.h-10{height:40px}.h-12{height:48px}.h-14{height:56px}.h-16{height:64px}.h-2{height:8px}.h-20{height:80px}.h-24{height:96px}.h-28{height:112px}.h-3{height:12px}.h-4{height:16px}.h-5{height:20px}.h-6{height:24px}.h-8{height:32px}.h-9{height:36px}.h-\\[101\\%\\]{height:101%}.h-full{height:100%}.h-screen{height:100vh}.max-h-\\[70vh\\]{max-height:70vh}.max-h-full{max-height:100%}.max-h-none{max-height:none}.min-h-full{min-height:100%}.w-0{width:0}.w-1{width:4px}.w-1\\/3{width:33.333333%}.w-10{width:40px}.w-12{width:48px}.w-14{width:56px}.w-2{width:8px}.w-2\\/3{width:66.666667%}.w-20{width:80px}.w-24{width:96px}.w-28{width:112px}.w-3{width:12px}.w-4{width:16px}.w-40{width:160px}.w-5{width:20px}.w-6{width:24px}.w-auto{width:auto}.w-full{width:100%}.w-min{width:-moz-min-content;width:min-content}.max-w-full{max-width:100%}.max-w-none{max-width:none}.max-w-xs{max-width:320px}.flex-shrink{flex-shrink:1}.flex-shrink-0{flex-shrink:0}.flex-grow{flex-grow:1}.origin-bottom{transform-origin:bottom}.origin-right{transform-origin:right}.origin-top{transform-origin:top}.\\!translate-y-full{--tw-translate-y:100%!important;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-translate-x-1\\/2{--tw-translate-x:-50%}.-translate-x-1\\/2,.-translate-y-1\\.5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\\.5{--tw-translate-y:-6px}.-translate-y-1\\/2{--tw-translate-y:-50%}.-translate-y-1\\/2,.translate-y-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-0{--tw-translate-y:0px}.translate-y-1\\.5{--tw-translate-y:6px}.-rotate-90,.translate-y-1\\.5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rotate-90{--tw-rotate:-90deg}.rotate-180{--tw-rotate:180deg}.rotate-180,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-90{--tw-rotate:90deg}.scale-95{--tw-scale-x:.95;--tw-scale-y:.95}.scale-95,.scale-y-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.scale-y-90{--tw-scale-y:.9}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-auto{cursor:auto}.cursor-default{cursor:default}.cursor-grabbing{cursor:grabbing}.cursor-none{cursor:none}.cursor-pointer{cursor:pointer}.touch-pan-x{--tw-pan-x:pan-x}.touch-pan-x,.touch-pan-y{touch-action:var(--tw-pan-x) var(--tw-pan-y) var(--tw-pinch-zoom)}.touch-pan-y{--tw-pan-y:pan-y}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.select-text{-webkit-user-select:text;-moz-user-select:text;user-select:text}.resize{resize:both}.\\!snap-none{scroll-snap-type:none!important}.snap-x{scroll-snap-type:x var(--tw-scroll-snap-strictness)}.snap-y{scroll-snap-type:y var(--tw-scroll-snap-strictness)}.snap-center{scroll-snap-align:center}.list-none{list-style-type:none}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.flex-row-reverse{flex-direction:row-reverse}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:4px}.gap-2{gap:8px}.gap-3{gap:12px}.gap-4{gap:16px}.gap-6{gap:24px}.gap-\\[1px\\]{gap:1px}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overscroll-contain{overscroll-behavior:contain}.overscroll-none{overscroll-behavior:none}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.rounded{border-radius:4px}.rounded-2xl{border-radius:16px}.rounded-\\[2\\.5rem\\]{border-radius:40px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:8px}.rounded-md{border-radius:6px}.rounded-xl{border-radius:12px}.\\!rounded-l-none{border-bottom-left-radius:0!important;border-top-left-radius:0!important}.\\!rounded-r-none{border-bottom-right-radius:0!important;border-top-right-radius:0!important}.rounded-l-sm{border-bottom-left-radius:2px;border-top-left-radius:2px}.rounded-r-sm{border-bottom-right-radius:2px;border-top-right-radius:2px}.rounded-t-xl{border-top-left-radius:12px;border-top-right-radius:12px}.border{border-width:1px}.border-2{border-width:2px}.border-4{border-width:4px}.border-t-\\[1px\\]{border-top-width:1px}.border-solid{border-style:solid}.border-none{border-style:none}.border-primary{--tw-border-opacity:1;border-color:rgb(184 92 56/var(--tw-border-opacity,1))}.border-stone-200{--tw-border-opacity:1;border-color:rgb(231 229 228/var(--tw-border-opacity,1))}.border-stone-400{--tw-border-opacity:1;border-color:rgb(168 162 158/var(--tw-border-opacity,1))}.border-stone-500{--tw-border-opacity:1;border-color:rgb(120 113 108/var(--tw-border-opacity,1))}.border-stone-600{--tw-border-opacity:1;border-color:rgb(87 83 78/var(--tw-border-opacity,1))}.border-textPrimary{--tw-border-opacity:1;border-color:rgb(251 130 82/var(--tw-border-opacity,1))}.border-opacity-30{--tw-border-opacity:.3}.border-opacity-70{--tw-border-opacity:.7}.bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity,1))}.bg-inherit{background-color:inherit}.bg-primary{--tw-bg-opacity:1;background-color:rgb(184 92 56/var(--tw-bg-opacity,1))}.bg-stone-100{--tw-bg-opacity:1;background-color:rgb(245 245 244/var(--tw-bg-opacity,1))}.bg-stone-300{--tw-bg-opacity:1;background-color:rgb(214 211 209/var(--tw-bg-opacity,1))}.bg-stone-500{--tw-bg-opacity:1;background-color:rgb(120 113 108/var(--tw-bg-opacity,1))}.bg-stone-600{--tw-bg-opacity:1;background-color:rgb(87 83 78/var(--tw-bg-opacity,1))}.bg-stone-800{--tw-bg-opacity:1;background-color:rgb(41 37 36/var(--tw-bg-opacity,1))}.bg-stone-900{--tw-bg-opacity:1;background-color:rgb(28 25 23/var(--tw-bg-opacity,1))}.bg-textPrimary{--tw-bg-opacity:1;background-color:rgb(251 130 82/var(--tw-bg-opacity,1))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.\\!bg-opacity-100{--tw-bg-opacity:1!important}.bg-opacity-40{--tw-bg-opacity:.4}.bg-opacity-50{--tw-bg-opacity:.5}.bg-opacity-70{--tw-bg-opacity:.7}.bg-opacity-80{--tw-bg-opacity:.8}.bg-opacity-90{--tw-bg-opacity:.9}.bg-none{background-image:none}.object-contain{-o-object-fit:contain;object-fit:contain}.p-0{padding:0}.p-0\\.5{padding:2px}.p-1{padding:4px}.p-2{padding:8px}.p-4{padding:16px}.p-6{padding:24px}.px-2{padding-left:8px;padding-right:8px}.px-3{padding-left:12px;padding-right:12px}.px-4{padding-left:16px;padding-right:16px}.px-5{padding-left:20px;padding-right:20px}.px-6{padding-left:24px;padding-right:24px}.px-8{padding-left:32px;padding-right:32px}.py-0\\.5{padding-bottom:2px;padding-top:2px}.py-1{padding-bottom:4px;padding-top:4px}.py-1\\.5{padding-bottom:6px;padding-top:6px}.py-2{padding-bottom:8px;padding-top:8px}.pb-6{padding-bottom:24px}.pb-7{padding-bottom:28px}.pb-8{padding-bottom:32px}.pl-1{padding-left:4px}.pr-2{padding-right:8px}.pt-1{padding-top:4px}.pt-1\\.5{padding-top:6px}.pt-12{padding-top:48px}.pt-16{padding-top:64px}.pt-20{padding-top:80px}.pt-5{padding-top:20px}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-sans{font-family:Helvetica,sans-serif}.text-base{font-size:16px;line-height:24px}.text-sm{font-size:14px;line-height:20px}.text-xl{font-size:20px;line-height:28px}.font-medium{font-weight:500}.font-normal{font-weight:400}.lowercase{text-transform:lowercase}.leading-none{line-height:1}.text-stone-100{--tw-text-opacity:1;color:rgb(245 245 244/var(--tw-text-opacity,1))}.text-stone-200{--tw-text-opacity:1;color:rgb(231 229 228/var(--tw-text-opacity,1))}.text-stone-300{--tw-text-opacity:1;color:rgb(214 211 209/var(--tw-text-opacity,1))}.text-stone-400{--tw-text-opacity:1;color:rgb(168 162 158/var(--tw-text-opacity,1))}.text-stone-50{--tw-text-opacity:1;color:rgb(250 250 249/var(--tw-text-opacity,1))}.text-stone-800{--tw-text-opacity:1;color:rgb(41 37 36/var(--tw-text-opacity,1))}.text-stone-900{--tw-text-opacity:1;color:rgb(28 25 23/var(--tw-text-opacity,1))}.text-textPrimary{--tw-text-opacity:1;color:rgb(251 130 82/var(--tw-text-opacity,1))}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-90{opacity:.9}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-neutral-950{--tw-shadow-color:#0a0a0a;--tw-shadow:var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-md{--tw-backdrop-blur:blur(12px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-bg{transition-duration:.15s;transition-property:background-color;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-0{transition-duration:0s}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-500{transition-duration:.5s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.children-pointer-events-auto>*{pointer-events:auto}.last\\:mb-0:last-child{margin-bottom:0}.last\\:border-b-transparent:last-child{border-bottom-color:transparent}@media (hover:hover) and (pointer:fine){.hover\\:bg-stone-100:hover{--tw-bg-opacity:1;background-color:rgb(245 245 244/var(--tw-bg-opacity,1))}.hover\\:bg-stone-300:hover{--tw-bg-opacity:1;background-color:rgb(214 211 209/var(--tw-bg-opacity,1))}.hover\\:bg-stone-50:hover{--tw-bg-opacity:1;background-color:rgb(250 250 249/var(--tw-bg-opacity,1))}.hover\\:bg-stone-500:hover{--tw-bg-opacity:1;background-color:rgb(120 113 108/var(--tw-bg-opacity,1))}.hover\\:bg-stone-900:hover{--tw-bg-opacity:1;background-color:rgb(28 25 23/var(--tw-bg-opacity,1))}.hover\\:bg-opacity-10:hover{--tw-bg-opacity:.1}.hover\\:bg-opacity-50:hover{--tw-bg-opacity:.5}.hover\\:bg-opacity-80:hover{--tw-bg-opacity:.8}.hover\\:text-stone-100:hover{--tw-text-opacity:1;color:rgb(245 245 244/var(--tw-text-opacity,1))}}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:outline-primary:focus{outline-color:#b85c38}@media (hover:hover) and (pointer:fine){.group:hover .group-hover\\:bg-stone-100{--tw-bg-opacity:1;background-color:rgb(245 245 244/var(--tw-bg-opacity,1))}.group:hover .group-hover\\:bg-opacity-20{--tw-bg-opacity:.2}}@media (min-width:300px){.\\32xs\\:gap-3{gap:12px}.\\32xs\\:px-3{padding-left:12px;padding-right:12px}}@media (min-width:640px){.sm\\:h-16{height:64px}.sm\\:w-\\[31rem\\]{width:496px}.sm\\:p-3{padding:12px}.sm\\:px-12{padding-left:48px;padding-right:48px}.sm\\:py-3{padding-bottom:12px;padding-top:12px}.sm\\:pt-18{padding-top:72px}.sm\\:pt-9{padding-top:36px}}@media (min-width:768px){.md\\:fixed{position:fixed}.md\\:left-auto{left:auto}.md\\:order-4{order:4}.md\\:inline-block{display:inline-block}.md\\:flex-col{flex-direction:column}.md\\:bg-transparent{background-color:transparent}.md\\:px-14{padding-left:56px;padding-right:56px}.md\\:px-8{padding-left:32px;padding-right:32px}.md\\:pb-5{padding-bottom:20px}.md\\:pb-6{padding-bottom:24px}.md\\:pt-12{padding-top:48px}.md\\:pt-20{padding-top:80px}}@media (min-width:1024px){.lg\\:px-10{padding-left:40px;padding-right:40px}.lg\\:px-16{padding-left:64px;padding-right:64px}.lg\\:pb-3{padding-bottom:12px}.lg\\:pb-4{padding-bottom:16px}}@media (min-width:1280px){.xl\\:px-12{padding-left:48px;padding-right:48px}.xl\\:px-20{padding-left:80px;padding-right:80px}}']]]),a0=Object.freeze(Object.defineProperty({__proto__:null,default:Qa},Symbol.toStringTag,{value:"Module"})),c0={class:"max-h-none max-w-none h-full w-full m-0 p-0 border-none outline-none"},u0={key:0,class:"fixed inset-0 h-[101%] flex justify-center items-center z-10 bg-black"},d0={class:"flex justify-between items-end"},f0={class:"inline-block children-pointer-events-auto"},p0={class:"inline-flex flex-col items-end gap-4 children-pointer-events-auto"},h0={class:"fixed pointer-events-none left-0 right-0 bottom-0"},g0={key:1,class:"fixed inline-block left-1/2 -translate-x-1/2 bottom-0 p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3"},m0=Object.freeze(Object.defineProperty({__proto__:null,default:be(ge({__name:"ReaderLayout",props:{loading:{type:Boolean},immediate:{type:Boolean},idle:{type:Boolean},controlsVisible:{type:Boolean},zooming:{type:Boolean},spaceTop:{type:null}},setup(e,{expose:t}){const n={mounted:i=>i.showModal(),beforeUnmount:i=>i.close()},o=ee(null);return t({rootEl:o}),(i,r)=>He((v(),D("dialog",c0,[U("div",{ref_key:"rootEl",ref:o,id:"reader-layout",class:de({"cursor-none":e.idle,"cursor-default":!e.idle,"bg-black":e.immediate||!e.loading,"opacity-0":!e.immediate&&e.loading,"duration-200 transition-colors":!e.immediate})},[e.loading&&e.immediate?(v(),D("div",u0,[j(ii)])):ae("",!0),ke(i.$slots,"default"),U("div",{id:"controls",class:de(["fixed pointer-events-none cursor-auto left-0 top-0 w-full h-full flex flex-col justify-between p-2 sm:p-3 pb-6 md:pb-5 lg:pb-3",{"opacity-100 z-20":e.controlsVisible,"opacity-0 -z-10":!e.controlsVisible}])},[U("div",{class:"flex gap-1 items-center children-pointer-events-auto relative z-30 flex-shrink-0 2xs:gap-3",style:Te({paddingTop:`${e.spaceTop||0}px`})},[ke(i.$slots,"top-controls")],4),U("div",d0,[U("div",f0,[ke(i.$slots,"bottom-left-controls")]),U("div",p0,[ke(i.$slots,"bottom-right-controls")])]),U("div",h0,[ke(i.$slots,"progress")])],2),e.controlsVisible||e.zooming?(v(),D("div",g0,[ke(i.$slots,"reset-zoom")])):ae("",!0)],2)])),[[n]])}}),[["styles",["#reader-layout{direction:ltr;font-family:Helvetica,sans-serif;font-size:16px;font-weight:400;height:100%;line-height:24px;overflow:hidden;overscroll-behavior:contain;pointer-events:auto;text-align:left;width:100%;--tw-text-opacity:1;color:rgb(245 245 244/var(--tw-text-opacity,1))}"]]])},Symbol.toStringTag,{value:"Module"})),v0={},b0={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"};function y0(e,t){return v(),D("svg",b0,[...t[0]||(t[0]=[U("path",{fill:"currentColor",d:"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46s46-20.595 46-46s-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1)])])}const w0=Object.freeze(Object.defineProperty({__proto__:null,default:be(v0,[["render",y0]])},Symbol.toStringTag,{value:"Module"})),x0="gear-second{height:0!important;opacity:0!important;pointer-events:none!important;width:0!important;z-index:-10!important}html.gear-second,html.gear-second *{scroll-behavior:auto!important;scrollbar-width:none!important}html.gear-second ::-webkit-scrollbar,html.gear-second::-webkit-scrollbar{display:none!important}html.gear-second body{touch-action:pan-x pan-y!important}html.gear-second body .m-content #progress-bar{display:none!important}html.gear-second body>:not(dialog[open]),html.gear-second>body~*{visibility:hidden!important}html.gear-second>body~*{display:none!important;height:0!important;left:100%!important;max-height:0!important;max-width:0!important;opacity:0!important;pointer-events:none!important;top:100%!important;width:0!important}.mp-scroll-container{max-height:100vh!important;overflow:hidden!important}html:has(body.mp-scroll-container){overflow:auto!important}",rn="gear-second",Mr={appVersion:void 0,immediate:void 0,raw:void 0,spec:void 0,siteMeta:void 0,page:0,spaceTop:void 0,touchDevice:void 0,entryId:void 0,isAutoShow:void 0,tourEnabled:void 0,offlineMode:void 0,defaultPreferences:void 0,onError:void 0,onCrash:void 0,onDispose:void 0,onFullScreenChanged:void 0,onControlsVisibilityChanged:void 0,onPageChanged:void 0,onOpenEntry:void 0,onAddEntry:void 0,onFinished:void 0,onHapticFeedback:void 0,onPressedBack:void 0,onSelectChapter:void 0,onTimeout:void 0,onDefaultPreferencesChanged:void 0,onOpenDefaultPreferences:void 0},kt={promise:void 0,data:_o({...Mr})};async function _0(e){var c,d,f;let t=!1,n=!1,o,i,r,s;const l=!!e.spaceTop||!!e.isAutoShow&&!!e.page||!!((d=(c=e.spec)==null?void 0:c.paging)!=null&&d.total&&Ia(e.spec.paging.total));(f=e.spec)!=null&&f.paging&&!l&&(e.spec={...e.spec,paging:void 0});const a=()=>{t||(t=!0,clearInterval(o),o=void 0,i!=null&&i.isConnected&&document.body.removeChild(i),document.documentElement.classList.remove(rn),kt.data.touchDevice||Object.assign(kt.data,Mr),kt.promise=void 0,io.clear())};if(Object.assign(kt.data,Mr,e.appVersion?e:ec(e),{immediate:l,onReady(){l||(r==null||r(),document.documentElement.classList.add(rn))},onError(){var p,b;a(),n?((p=e.onDispose)==null||p.call(e),(b=e.onError)==null||b.call(e)):s==null||s()},onDispose:()=>{var p;a(),(p=e==null?void 0:e.onDispose)==null||p.call(e)},onControlsVisibilityChanged(p){var b,y;(b=e.onFullScreenChanged)==null||b.call(e,!p),(y=e.onControlsVisibilityChanged)==null||y.call(e,p)}}),kt.promise)return await kt.promise;const u=p=>{Object.assign(kt.data,kt.data.appVersion?p:ec(p))};return kt.promise=new Promise(p=>{r=()=>{n||(n=!0,p({updateArgs:u,dispose:a,back:()=>io.trigger()}))},s=()=>{n||p(void 0)},S0().then(()=>{if(t){s==null||s();return}i=document.createElement(rn),l?(document.documentElement.classList.add(rn),document.body.appendChild(i),setTimeout(()=>r==null?void 0:r())):document.body.appendChild(i);let b=0;o=setInterval(()=>{if(++b===30||t){clearInterval(o),o=void 0;return}i.isConnected||(document.documentElement.classList.add(rn),document.body.appendChild(i))},100)})}),await kt.promise}function ec(e){if(!["autoPlay","readerStyle","direction","autoNextSeconds","defaultSpeed","defaultGap","hideControlsEvent","progressSize","pinchToZoom","tapZone"].some(p=>p in e))return e;const{autoPlay:n,readerStyle:o,direction:i,autoNextSeconds:r,defaultSpeed:s,defaultGap:l,hideControlsEvent:a,progressSize:u,pinchToZoom:c,tapZone:d,...f}=e;return{...f,defaultPreferences:{autoPlay:n,readerStyle:o,direction:i,autoNextSeconds:r,speed:s,gap:l,hideControlsEvent:a,progressSize:u,pinchToZoom:c,tapZone:d}}}async function S0(){if(window.customElements.get(rn))return;const e=await k0();if(window.customElements.get(rn))return;const t=document.createElement("style"),n=x0;t.appendChild(document.createTextNode(n)),document.head.appendChild(t);const o=Ed({styles:[e],data:()=>({readerData:kt.data}),render(){return ul(Qa,this.readerData)}});window.customElements.define(rn,o)}async function k0(){const e=Object.assign({"./App.vue":a0,"./GearSecond.vue":Nm,"./GearThird.vue":i0,"./components/AutoNext.vue":jf,"./components/ButtonWebFullScreen.vue":zp,"./components/ChapterNav.vue":rh,"./components/DefaultPreferencesForm.vue":Vh,"./components/DirectionToast.vue":Kh,"./components/GearControlsLayout.vue":Xh,"./components/GearLayout.vue":ig,"./components/GearThirdControlsLayout.vue":Zm,"./components/GesturesContainer.vue":yg,"./components/HelpScreen.vue":mf,"./components/MangaPreferencesForm.vue":hg,"./components/NovelBody.vue":o0,"./components/NovelPreferencesForm.vue":Ah,"./components/PageNav.vue":gg,"./components/PauseToast.vue":mg,"./components/ProgressBar.vue":bg,"./components/ReaderBody.vue":Cg,"./components/ReaderImg.vue":xg,"./components/ReaderLayout.vue":m0,"./components/ReaderTour.vue":yf,"./components/SettingsBottomSheet.vue":qg,"./components/TapZonePreview.vue":qh,"./components/base/BaseButton.vue":If,"./components/base/BottomSheet.vue":Og,"./components/base/ButtonDropdown.vue":Yp,"./components/base/ButtonIcon.vue":Nf,"./components/base/ButtonOutline.vue":Ph,"./components/base/DropdownMenu.vue":Lp,"./components/base/InputPercentage.vue":ah,"./components/base/InputSelect.vue":dh,"./components/base/InputSwitcher.vue":gh,"./components/base/LoadingIndicator.vue":tg,"./components/base/TabBar.vue":Dg,"./components/base/TableField.vue":vh,"./components/buttons/ButtonBack.vue":Wf,"./components/buttons/ButtonEntry.vue":Qf,"./components/buttons/ButtonHide.vue":ip,"./components/buttons/ButtonPlay.vue":pp,"./components/buttons/ButtonResetZoom.vue":wp,"./components/buttons/ButtonSettings.vue":Cp,"./components/fields/FieldContrast.vue":bh,"./components/fields/FieldFontFamily.vue":Ih,"./components/icons/IconBack.vue":Ff,"./components/icons/IconBookmarkNew.vue":Jf,"./components/icons/IconBookmarked.vue":Zf,"./components/icons/IconChevronLeft.vue":Qp,"./components/icons/IconChevronRight.vue":oh,"./components/icons/IconClose.vue":Eg,"./components/icons/IconDouble.vue":ag,"./components/icons/IconDoubleSkip.vue":fg,"./components/icons/IconExclamationCircle.vue":w0,"./components/icons/IconFullscreen.vue":Ep,"./components/icons/IconFullscreenExit.vue":Dp,"./components/icons/IconHelp.vue":Lg,"./components/icons/IconLandscape.vue":_h,"./components/icons/IconLoading.vue":Rp,"./components/icons/IconMoreVert.vue":Rg,"./components/icons/IconNext.vue":Wh,"./components/icons/IconPause.vue":ap,"./components/icons/IconPlay.vue":fp,"./components/icons/IconPlus.vue":$f,"./components/icons/IconPortrait.vue":Th,"./components/icons/IconReaderExit.vue":op,"./components/icons/IconSettings.vue":kp,"./components/icons/IconTextDecre.vue":Jm,"./components/icons/IconTextIncre.vue":n0,"./components/icons/IconTriangle.vue":qp,"./components/icons/IconZoom.vue":vp}),t=[];for(const n in e){const o=e[n];t.push(o.default.styles)}return t.join("")}return _0});
|