trackkun-dom 0.2.0 → 0.3.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 +1 -1
- package/init.js +1 -1
- package/package.json +1 -1
- package/specs.json +1 -1
- package/tags.json +1 -1
package/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(W,q){typeof exports=="object"&&typeof module<"u"?q(exports):typeof define=="function"&&define.amd?define(["exports"],q):(W=typeof globalThis<"u"?globalThis:W||self,q(W._trackkun_={}))})(this,function(W){"use strict";function q(r){let e=!1;return new Promise((t,a)=>{Promise.all(r.map(async n=>{const l=await n;!e&&l&&(e=!0,t(l))})).then(()=>{e||t(void 0)})})}const pt={text:dt,attr:gt,"attr-contain":ht,value:ft,row:vt};function g(r,e={}){if(!r)return;const{root:t=document.documentElement,returnAll:a,preProcess:n}=e,l=X(r);if(l.length>1){for(let p=0;p<l.length;p+=1){const d=g(l[p],e);if(d!=null&&d.length)return d}return}const[s,i]=r.split("|");if(!i)return;const c=(i!=null&&i.startsWith("[")&&i.endsWith("]")?i.substring(1,i.length-1).split(","):[i]).map(p=>{const d=p.indexOf(":"),h=d!==-1;return{action:h?p.substring(0,d):p,param:h?p.substring(d+1):""}}),o=s?Array.from(t.querySelectorAll(s)):[t];if(!o.length)return a?[]:void 0;n&&n(o);const u=[];for(const p of o)for(const d of c){const h=pt[d.action],v=h(p,d.param);if(v){if(a){u.push(v);break}return v}}return a?u:void 0}function dt(r){return Array.from(r.childNodes).filter(e=>e.nodeType===3).map(e=>k(e.textContent)).filter(Boolean).join(" ").trim()||k(r.textContent)}function gt(r,e){return k(r.getAttribute(e))}function ht(r,e){let t=r.getAttribute(e);if(!t){const a=r.getAttributeNames().find(n=>n.includes(e));a&&(t=r.getAttribute(a))}return k(t)}function X(r){const e=[],t=r.split("||").map(a=>a.trim()).filter(Boolean);return t.forEach((a,n)=>{if(a.includes("|")){e.push(a);return}const l=t[n+1];l&&(t[n+1]=`${a},${l}`)}),e}function ft(r){return r.value}function vt(r,e){var t,a,n,l;if(!e)return;const s=(t=k(r.textContent))==null?void 0:t.toLowerCase(),i=e.toLowerCase();if(!(s!==i&&s!==`${i}:`))return k((l=(a=r.nextElementSibling)==null?void 0:a.textContent)!=null?l:(n=r.nextSibling)==null?void 0:n.textContent)}function k(r){if(r)return r?.replace(/(\n|\t)/g," ").trim()||void 0}async function de(r,e,t){const a=await t(()=>{r=0});if(a!==void 0)return a;if(!(r<=0))return await new Promise(n=>{setTimeout(async()=>{const l=await de(r-1,e,t);n(l)},e)})}async function N(r,e,t=0){var a;const n=(a=e.root)!=null?a:document.documentElement;return de(e.lazy===!0?200:0,100,()=>{var l;const s=e.all===!0?Array.from(n.querySelectorAll(r)):(l=n.querySelector(r))!=null?l:void 0;return(e.all?!(s!=null&&s.length):!s)?void 0:s})}const mt=/(vol(ume|\.)?\s*(\d+))/i,yt=/(ch(ap(t(er)?|\.)?|\.)?|^#)\s*(\d+([_-~,.]\d+)?)/i,wt=/\d+([_-~,.]\d+)?/,bt=/[_-~,]/,Rt=/^[^a-zA-Z0-9]*|[^a-zA-Z0-9]*$/g;function V(r,e){var t;if(!r||!r)return;if(!isNaN(+r))return{chap:+r};const a=r.match(mt),n=a!=null&&a[0]?r.replace(a[0],"").trim():r,l=n.match(yt),s=n.match(wt),i=(t=l?.[5])!=null?t:s?.[0];if(!i)return;const c=+i.replace(bt,".");if(isNaN(c))return;const o=a?.[3],u=o&&!isNaN(+o)?+o:void 0,p=n.replace((l||s)[0],"").replace(Rt,""),d=e&&p.startsWith(e)?p.replace(e,""):p;return{vol:u,chap:c,label:d||void 0}}var Ot=Object.defineProperty,ge=Object.getOwnPropertySymbols,St=Object.prototype.hasOwnProperty,$t=Object.prototype.propertyIsEnumerable,he=(r,e,t)=>e in r?Ot(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,Pt=(r,e)=>{for(var t in e||(e={}))St.call(e,t)&&he(r,t,e[t]);if(ge)for(var t of ge(e))$t.call(e,t)&&he(r,t,e[t]);return r};function fe(r,e){var t,a;const n=[...e],l=[];let s=-1,i=-1;for(let o=0;o<r.length&&!(!n.length&&o>=10);o++){const u=Pt({},r[o]),p=n.findIndex(v=>v.slug===u.slug&&v.name===u.name),d=p===-1?void 0:n.splice(p,1)[0],h=!d||((t=d.chapters[0])==null?void 0:t.chap)!==((a=u.chapters[0])==null?void 0:a.chap);p!==-1&&(i=o),h&&(s=o,u.changed=!0),l.push(u)}if(s===-1)return[];if(n.length&&n.length!==e.length){const o=Math.max(10,i+1);l.splice(o);for(let u=i+1;u<l.length;u++)l[u].changed=!1;return l}const c=Math.min(Math.max(s+1,10),Math.max(i+1,100));return l.slice(0,c)}function G(r,e){if(!(e!=null&&e.length))return;const t={};r.forEach(({id:n,name:l,altNames:s})=>{t[ee(l)]=n,s&&s.forEach(i=>{t[ee(i)]=n})});const a=e.map(n=>t[ee(n)]).filter(Boolean);return a.length===0?void 0:Array.from(new Set(a)).sort((n,l)=>n-l)}function ee(r){const e=r.toLowerCase().replaceAll(" ","");return e[e.length-1]==="s"?e.substring(0,e.length-1):e}function E(r){return r.sort((e,t)=>e.vol===void 0||t.vol===void 0?t.chap-e.chap:t.vol-e.vol||t.chap-e.chap),Dt(r)}function Dt(r){let e;for(let t=r.length-1;t>=0;t--){const a=r[t];a.vol!==void 0?e=a.vol:e!==void 0&&(a.inferVol=e)}return r}var jt=Object.defineProperty,xt=Object.defineProperties,Tt=Object.getOwnPropertyDescriptors,ve=Object.getOwnPropertySymbols,Nt=Object.prototype.hasOwnProperty,Mt=Object.prototype.propertyIsEnumerable,me=(r,e,t)=>e in r?jt(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,Ct=(r,e)=>{for(var t in e||(e={}))Nt.call(e,t)&&me(r,t,e[t]);if(ve)for(var t of ve(e))Mt.call(e,t)&&me(r,t,e[t]);return r},Bt=(r,e)=>xt(r,Tt(e));function ye(r,e){const t={};return r.forEach(a=>{Object.values(a.chapters.reduce((n,l)=>{const s=l.lang||e||"default";return n[s]||(n[s]=[]),n[s].push(l),n},{})).forEach(n=>{var l,s;const i=(s=(l=n[0])==null?void 0:l.lang)!=null?s:e,c=`${a.slug}:${i||""}`;t[c]?(t[c].chapters.push(...n),E(t[c].chapters)):t[c]=Bt(Ct({},a),{lang:i})})}),Object.values(t)}const _t=[{regex:/(sec|giây)/,seconds:1},{regex:/(min|phút)/,seconds:60},{regex:/(hour|giờ)/,seconds:3600},{regex:/(day|ngày)/,seconds:86400},{regex:/(week|tuần)/,seconds:604800},{regex:/(month|tháng)/,seconds:2592e3},{regex:/(year|năm)/,seconds:31536e3}];function F(r){const e=r?.toLowerCase();if(!e||e.includes("now"))return Date.now();if(e.includes("yesterday"))return Date.now()-864e5;const t=new Date(e);if(t instanceof Date){const l=t.valueOf();if(!isNaN(l))return t.getHours()===0&&t.getMinutes()===0?Math.min(Date.now(),l+432e5):l}const a=_t.find(l=>l.regex.test(e));if(!a)return;const n=e.split(" ").filter(Boolean);for(let l=0;l<n.length;l++){const s=n[l],i=s==="a"||s==="an"?1:+s;if(!i)continue;if(i<0)return;const c=Date.now()-i*a.seconds*1e3;return c>0?c:void 0}}function H(r,e=location.origin){if(!r)return;const t=r.startsWith("//")?`${location.protocol}${r}`:r;return t.startsWith(e)?t.replace(e,""):t}function J(r,e){if(!r)return"/";const t=r.replace("{titleSlug}",e),a=t.endsWith("/")?t:t+"/";return a.startsWith("/")?a:"/"+a}function we(r,{removeTrailingSlash:e=!0}={}){if(!r)return;const t=e&&r.endsWith("/")?r.slice(0,-1):r;try{return new URL(t)}catch{return}}function D(r){var e,t;if(!(!r||typeof r!="string"))return r.startsWith("http://")||r.startsWith("https://")?(e=we(r))==null?void 0:e.pathname:r.startsWith("//")?(t=we(`https:${r}`))==null?void 0:t.pathname:r}var j=(r=>(r.title="title",r.reader="reader",r.update="update",r.search="search",r))(j||{}),It=Object.defineProperty,At=Object.defineProperties,Et=Object.getOwnPropertyDescriptors,Y=Object.getOwnPropertySymbols,be=Object.prototype.hasOwnProperty,Re=Object.prototype.propertyIsEnumerable,Oe=(r,e,t)=>e in r?It(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,te=(r,e)=>{for(var t in e||(e={}))be.call(e,t)&&Oe(r,t,e[t]);if(Y)for(var t of Y(e))Re.call(e,t)&&Oe(r,t,e[t]);return r},Se=(r,e)=>At(r,Et(e)),$e=(r,e)=>{var t={};for(var a in r)be.call(r,a)&&e.indexOf(a)<0&&(t[a]=r[a]);if(r!=null&&Y)for(var a of Y(r))e.indexOf(a)<0&&Re.call(r,a)&&(t[a]=r[a]);return t};let Lt=class pe{constructor(e){this.methodsMap={[j.title]:()=>this.getRawTitleData(),[j.reader]:()=>this.getRawReaderData(),[j.update]:()=>this.getRawReleasesData(),[j.search]:()=>this.getRawSearchData()};var t;this.spec=e.spec,this.siteMeta=e.siteMeta,this.tags=e.tags,this.oldRawReleases=e.oldRawReleases,this.getGlobalData=(t=e.getGlobalData)!=null?t:zt}async getRawPageByType(e){const t=await this.methodsMap[e](),a=location.origin+location.pathname;return{type:e,is404:pe._is404Page(this.spec),specId:this.spec.id,siteName:g(this.spec.name),url:a,data:t}}async getRawReleasesData(){var e,t;if(!((t=(e=this.spec)==null?void 0:e.update)!=null&&t.title))return;const a=this.spec.update.title,{chapter:n}=a,l=$e(a,["chapter"]);if(!l.sel||!l.name||!(n!=null&&n.sel)||!(n!=null&&n.label))return;const s=await N(l.sel,{lazy:!0,all:!0});if(!(s!=null&&s.length))return;const i=s.slice(0,100).map(o=>{const u=g(l.url,{root:o}),p=D(u),d=g(l.name,{root:o}),h=g(l.at,{root:o});if(!(!p||!d))return{titleEl:o,id:g(l.id,{root:o}),path:p,img:H(g(l.img,{root:o})),name:d,lang:g(l.lang,{root:o}),at:h?F(h):void 0}}).filter(Boolean);if(!i.length)return;const c=await Promise.all(i.map(async o=>{var u;const p=o,{path:d,titleEl:h,lang:v,at:w}=p,f=$e(p,["path","titleEl","lang","at"]),R=this.resolveTitleSlug(d),m=(u=await this.getRawChapters(n,{root:h,titleSlug:R,titleName:f?.name}))!=null?u:[];return te({slug:R,chapters:v||w?m.map(b=>{var O,$;return Se(te({},b),{lang:(O=b.lang)!=null?O:v,ts:($=b.ts)!=null?$:w})}):m},f)}));return this.finalizeRawReleasesData({rawReleases:c})}async getRawTitleData(){var e,t,a;if(!((e=this.spec)!=null&&e.title))return;const n=this.spec.title;if(!n.sel||!n.name||!await N(n.sel,{lazy:!!this.spec.title.lazy}))return;const l=g(n.name);if(!l)return;const s=this.resolveTitleSlug(location.pathname);if(!s)return;let i=(t=g(n.tags,{returnAll:!0}))!=null?t:[];i.length===1&&(i=i[0].split(",").map(u=>u.trim()).filter(Boolean));const c=g(n.type),o=g(n.langs,{returnAll:!0});return{id:g(n.id),url:location.origin+location.pathname,slug:s,name:l,langs:o!=null&&o.length?o:n.langs&&this.siteMeta.defaultLang?[this.siteMeta.defaultLang]:void 0,tags:G(this.tags,[...i??[],...c?[c]:[]]),img:H(g(n.img)),chapters:(a=await this.getRawChapters(n.chapter,{lazy:!0,titleSlug:s,titleName:l}))!=null?a:[]}}async getRawReaderData(){var e,t,a,n,l,s;const{spec:i,siteMeta:c}=this;if(!(i!=null&&i.reader)||!await pe._isReaderPage(i.reader))return;const o=i.reader.title,u=document.querySelector(o.sel);if(!u)return;const p=g(o.name,{root:u}),d=g(o.url,{root:u}),h=this.resolveTitleSlug(d);if(!p||!d||!h)return;const v=(t=await this.getRawChapters((e=i.reader)==null?void 0:e.chapter,{titleSlug:h,titleName:p}))!=null?t:[],w=(a=g(i.reader.label))==null?void 0:a.toLowerCase().replace(p.toLowerCase(),"");if(!w)return;const{vol:f,chap:R=0}=V(w,p)||{};let m;const b=(n=g(i.reader.img,{returnAll:!0,preProcess(x){const T=x.map(C=>+(C.getAttribute("height")||0)/+(C.getAttribute("width")||1));T.some(C=>C>2.5)?m=!0:T.filter(Boolean).length>Math.max(1,T.length-2)&&(m=!1)}}))!=null?n:[];if(!b.length)return;const O=J(c.readerBase,h),$=c.readerBase.split("/").indexOf("{lang}"),S=$!==-1?location.pathname.substring(1).split("/")[$]:void 0,P=S?O.replace("{lang}",S):O,y=(l=S??g(i.reader.lang))!=null?l:i.reader.lang?this.siteMeta.defaultLang:void 0;return{isWebtoon:m,vol:f,inferVol:(s=v.find(x=>x.vol===f&&x.chap===R))==null?void 0:s.inferVol,chap:R,lang:y,slug:this.resolveReaderSlug(P,location.pathname),nextSlug:this._findNeighborSlug({sel:i.reader.next,basePath:P}),prevSlug:this._findNeighborSlug({sel:i.reader.prev,basePath:P}),basePath:P,imgs:b,imgsLocator:i.reader.img,title:{id:g(o.id),url:d,slug:h,name:p,langs:y?[y]:void 0,chapters:v}}}async getRawSearchData(){var e;const t=(e=this.spec.search)==null?void 0:e.title;if(!t)return;const{chapter:a}=t,n=[];return await Promise.all(Array.from(document.querySelectorAll(t.sel)).map(async l=>{var s;const i=g(t.url,{root:l}),c=D(i),o=g(t.name,{root:l}),u=this.resolveTitleSlug(c);!c||!o||!u||n.push({slug:u,img:g(t.img,{root:l}),name:o,chapters:(s=await this.getRawChapters(a,{root:l,titleSlug:u,titleName:o}))!=null?s:[]})})),n.length?{rawReleases:n}:void 0}async getRawChapters(e,{root:t=document.documentElement,titleSlug:a="",titleName:n,lazy:l=!0}){var s;if(!e)return;const i=[],c=await N(e.sel,{root:t,all:!0,lazy:l});if(!(c!=null&&c.length))return i;const o=(c??[]).map(f=>({id:g(e.id,{root:f}),label:g(e.label,{root:f}),url:g(e.url,{root:f}),at:g(e.at,{root:f})})),u=o.map(({label:f})=>V(f,n)),p=(s=u[1])==null?void 0:s.chap;!u[0]&&(p===void 0||p<=1)&&(u[0]={label:o[0].label,chap:0});const{readerBase:d}=this.siteMeta,h=J(d,a),v=d.split("/").indexOf("{lang}"),w=v!==-1;return u.forEach((f,R)=>{var m;if(!f)return;const{id:b,url:O,at:$}=o[R],S=D(O);if(!S)return;const P=w?S?.substring(1).split("/")[v]:void 0,y=this.resolveReaderSlug(P?h.replace("{lang}",P):h,S);i.push(Se(te({},f),{id:b,slug:y,lang:P,ts:F($)||((m=i[i.length+1])==null?void 0:m.ts)||Date.now()}))}),E(i)}resolveReaderSlug(e,t){return t.startsWith(e)?t.replace(e,""):t}resolveTitleSlug(e){var t;if(typeof e!="string")return;const a=(t=D(e))==null?void 0:t.split("/").filter(Boolean);return!a||!a.length?e:a[a.length-1]}finalizeRawReleasesData(e){var t,a;const n=(a=(t=this.spec.update)==null?void 0:t.title)!=null&&a.lang?this.siteMeta.defaultLang:void 0,l=ye(e.rawReleases,n);if(l.length)return{rawReleases:this.oldRawReleases?fe(l,this.oldRawReleases):l}}static async _isReaderPage(e){const{sel:t,img:a}=e;if(!t||!a||!await N(t,{lazy:!!e.lazy}))return!1;const n=X(a).map(l=>l.split("|")[0]).join(",");return!!await N(n,{lazy:!0})}_findNeighborSlug({sel:e,basePath:t}){const a=g(e);if(!a||a.startsWith("#")||a.startsWith("/#"))return;const n=D(a);return n?this.resolveReaderSlug(t,n):void 0}static _is404Page(e){return e[404]&&document.querySelector(e[404])?!0:document.title.toLowerCase().includes("not found")}};async function zt(r){let e=window;const t={__html__:document.documentElement};for(let a=0;a<r.length;a++){const{attr:n,args:l}=r[a];if(!(n in e))return;e=l?e[n](...l.map(s=>{var i;return(i=t[s])!=null?i:s})):e[n]}return e===window?void 0:e}var Wt=Object.defineProperty,qt=Object.defineProperties,kt=Object.getOwnPropertyDescriptors,Z=Object.getOwnPropertySymbols,Pe=Object.prototype.hasOwnProperty,De=Object.prototype.propertyIsEnumerable,je=(r,e,t)=>e in r?Wt(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,re=(r,e)=>{for(var t in e||(e={}))Pe.call(e,t)&&je(r,t,e[t]);if(Z)for(var t of Z(e))De.call(e,t)&&je(r,t,e[t]);return r},xe=(r,e)=>qt(r,kt(e)),Te=(r,e)=>{var t={};for(var a in r)Pe.call(r,a)&&e.indexOf(a)<0&&(t[a]=r[a]);if(r!=null&&Z)for(var a of Z(r))e.indexOf(a)<0&&De.call(r,a)&&(t[a]=r[a]);return t};class _{constructor(e){this.methodsMap={[j.title]:()=>this.getRawTitleData(),[j.reader]:()=>this.getRawReaderData(),[j.update]:()=>this.getRawReleasesData(),[j.search]:()=>this.getRawSearchData()};var t;this.spec=e.spec,this.siteMeta=e.siteMeta,this.tags=e.tags,this.oldRawReleases=e.oldRawReleases,this.getGlobalData=(t=e.getGlobalData)!=null?t:Ut}async getRawPageByType(e){const t=await this.methodsMap[e](),a=location.origin+location.pathname;return{type:e,is404:_._is404Page(this.spec),specId:this.spec.id,siteName:g(this.spec.name),url:a,data:t}}async getRawReleasesData(){var e,t;if(!((t=(e=this.spec)==null?void 0:e.update)!=null&&t.title))return;const a=this.spec.update.title,{chapter:n}=a,l=Te(a,["chapter"]);if(!l.sel||!l.name||!(n!=null&&n.sel)||!(n!=null&&n.label))return;const s=await N(l.sel,{lazy:!0,all:!0});if(!(s!=null&&s.length))return;const i=s.slice(0,100).map(o=>{const u=g(l.url,{root:o}),p=D(u),d=g(l.name,{root:o}),h=g(l.at,{root:o});if(!(!p||!d))return{titleEl:o,id:g(l.id,{root:o}),path:p,img:H(g(l.img,{root:o})),name:d,lang:g(l.lang,{root:o}),at:h?F(h):void 0}}).filter(Boolean);if(!i.length)return;const c=await Promise.all(i.map(async o=>{var u;const p=o,{path:d,titleEl:h,lang:v,at:w}=p,f=Te(p,["path","titleEl","lang","at"]),R=this.resolveTitleSlug(d),m=(u=await this.getRawChapters(n,{root:h,titleSlug:R,titleName:f?.name}))!=null?u:[];return re({slug:R,chapters:v||w?m.map(b=>{var O,$;return xe(re({},b),{lang:(O=b.lang)!=null?O:v,ts:($=b.ts)!=null?$:w})}):m},f)}));return this.finalizeRawReleasesData({rawReleases:c})}async getRawTitleData(){var e,t,a;if(!((e=this.spec)!=null&&e.title))return;const n=this.spec.title;if(!n.sel||!n.name||!await N(n.sel,{lazy:!!this.spec.title.lazy}))return;const l=g(n.name);if(!l)return;const s=this.resolveTitleSlug(location.pathname);if(!s)return;let i=(t=g(n.tags,{returnAll:!0}))!=null?t:[];i.length===1&&(i=i[0].split(",").map(u=>u.trim()).filter(Boolean));const c=g(n.type),o=g(n.langs,{returnAll:!0});return{id:g(n.id),url:location.origin+location.pathname,slug:s,name:l,langs:o!=null&&o.length?o:n.langs&&this.siteMeta.defaultLang?[this.siteMeta.defaultLang]:void 0,tags:G(this.tags,[...i??[],...c?[c]:[]]),img:H(g(n.img)),chapters:(a=await this.getRawChapters(n.chapter,{lazy:!0,titleSlug:s,titleName:l}))!=null?a:[]}}async getRawReaderData(){var e,t,a,n,l,s;const{spec:i,siteMeta:c}=this;if(!(i!=null&&i.reader)||!await _._isReaderPage(i.reader))return;const o=i.reader.title,u=document.querySelector(o.sel);if(!u)return;const p=g(o.name,{root:u}),d=g(o.url,{root:u}),h=this.resolveTitleSlug(d);if(!p||!d||!h)return;const v=(t=await this.getRawChapters((e=i.reader)==null?void 0:e.chapter,{titleSlug:h,titleName:p}))!=null?t:[],w=(a=g(i.reader.label))==null?void 0:a.toLowerCase().replace(p.toLowerCase(),"");if(!w)return;const{vol:f,chap:R=0}=V(w,p)||{};let m;const b=(n=g(i.reader.img,{returnAll:!0,preProcess(x){const T=x.map(C=>+(C.getAttribute("height")||0)/+(C.getAttribute("width")||1));T.some(C=>C>2.5)?m=!0:T.filter(Boolean).length>Math.max(1,T.length-2)&&(m=!1)}}))!=null?n:[];if(!b.length)return;const O=J(c.readerBase,h),$=c.readerBase.split("/").indexOf("{lang}"),S=$!==-1?location.pathname.substring(1).split("/")[$]:void 0,P=S?O.replace("{lang}",S):O,y=(l=S??g(i.reader.lang))!=null?l:i.reader.lang?this.siteMeta.defaultLang:void 0;return{isWebtoon:m,vol:f,inferVol:(s=v.find(x=>x.vol===f&&x.chap===R))==null?void 0:s.inferVol,chap:R,lang:y,slug:this.resolveReaderSlug(P,location.pathname),nextSlug:this._findNeighborSlug({sel:i.reader.next,basePath:P}),prevSlug:this._findNeighborSlug({sel:i.reader.prev,basePath:P}),basePath:P,imgs:b,imgsLocator:i.reader.img,title:{id:g(o.id),url:d,slug:h,name:p,langs:y?[y]:void 0,chapters:v}}}async getRawSearchData(){var e;const t=(e=this.spec.search)==null?void 0:e.title;if(!t)return;const{chapter:a}=t,n=[];return await Promise.all(Array.from(document.querySelectorAll(t.sel)).map(async l=>{var s;const i=g(t.url,{root:l}),c=D(i),o=g(t.name,{root:l}),u=this.resolveTitleSlug(c);!c||!o||!u||n.push({slug:u,img:g(t.img,{root:l}),name:o,chapters:(s=await this.getRawChapters(a,{root:l,titleSlug:u,titleName:o}))!=null?s:[]})})),n.length?{rawReleases:n}:void 0}async getRawChapters(e,{root:t=document.documentElement,titleSlug:a="",titleName:n,lazy:l=!0}){var s;if(!e)return;const i=[],c=await N(e.sel,{root:t,all:!0,lazy:l});if(!(c!=null&&c.length))return i;const o=(c??[]).map(f=>({id:g(e.id,{root:f}),label:g(e.label,{root:f}),url:g(e.url,{root:f}),at:g(e.at,{root:f})})),u=o.map(({label:f})=>V(f,n)),p=(s=u[1])==null?void 0:s.chap;!u[0]&&(p===void 0||p<=1)&&(u[0]={label:o[0].label,chap:0});const{readerBase:d}=this.siteMeta,h=J(d,a),v=d.split("/").indexOf("{lang}"),w=v!==-1;return u.forEach((f,R)=>{var m;if(!f)return;const{id:b,url:O,at:$}=o[R],S=D(O);if(!S)return;const P=w?S?.substring(1).split("/")[v]:void 0,y=this.resolveReaderSlug(P?h.replace("{lang}",P):h,S);i.push(xe(re({},f),{id:b,slug:y,lang:P,ts:F($)||((m=i[i.length+1])==null?void 0:m.ts)||Date.now()}))}),E(i)}resolveReaderSlug(e,t){return t.startsWith(e)?t.replace(e,""):t}resolveTitleSlug(e){var t;if(typeof e!="string")return;const a=(t=D(e))==null?void 0:t.split("/").filter(Boolean);return!a||!a.length?e:a[a.length-1]}finalizeRawReleasesData(e){var t,a;const n=(a=(t=this.spec.update)==null?void 0:t.title)!=null&&a.lang?this.siteMeta.defaultLang:void 0,l=ye(e.rawReleases,n);if(l.length)return{rawReleases:this.oldRawReleases?fe(l,this.oldRawReleases):l}}static async _isReaderPage(e){const{sel:t,img:a}=e;if(!t||!a||!await N(t,{lazy:!!e.lazy}))return!1;const n=X(a).map(l=>l.split("|")[0]).join(",");return!!await N(n,{lazy:!0})}_findNeighborSlug({sel:e,basePath:t}){const a=g(e);if(!a||a.startsWith("#")||a.startsWith("/#"))return;const n=D(a);return n?this.resolveReaderSlug(t,n):void 0}static _is404Page(e){return e[404]&&document.querySelector(e[404])?!0:document.title.toLowerCase().includes("not found")}}async function Ut(r){let e=window;const t={__html__:document.documentElement};for(let a=0;a<r.length;a++){const{attr:n,args:l}=r[a];if(!(n in e))return;e=l?e[n](...l.map(s=>{var i;return(i=t[s])!=null?i:s})):e[n]}return e===window?void 0:e}class Ne extends _{resolveTitleSlug(e){var t;return(t=D(e))==null?void 0:t.split("/").filter(Boolean)[1]}}Ne.specId="bato";function Vt(){return Math.random().toString(16).slice(2)}async function Gt({addListener:r,removeListener:e,transform:t,filter:a,handler:n,onTimeout:l,timeout:s,once:i}){return new Promise(c=>{r(p);const o=()=>i===!0&&e(p),u=s?setTimeout(()=>{o(),c(void 0),l?.()},s):void 0;async function p(d,...h){d=t?t(d):d,d!==void 0&&(!a||a(d,...h))&&(o(),c(d),n?.(d,...h),u&&clearTimeout(u))}})}var Ft=Object.defineProperty,Me=Object.getOwnPropertySymbols,Ht=Object.prototype.hasOwnProperty,Jt=Object.prototype.propertyIsEnumerable,Ce=(r,e,t)=>e in r?Ft(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,Yt=(r,e)=>{for(var t in e||(e={}))Ht.call(e,t)&&Ce(r,t,e[t]);if(Me)for(var t of Me(e))Jt.call(e,t)&&Ce(r,t,e[t]);return r};async function Zt(r){const e=await Gt(Yt({addListener:t=>window.addEventListener("message",t),removeListener:t=>window.removeEventListener("message",t)},r));return e?.data}async function Kt(r){var e;const{receiverWindow:t,timeout:a,targetOrigin:n,event:l,args:s}=r,i={reqId:Vt(),event:l,args:s};(e=t||window)==null||e.postMessage(i,n??"*");const c=await Zt({filter:o=>{var u;return((u=o?.data)==null?void 0:u.resId)===i.reqId},timeout:a??3e4,once:!0});return c?.result}const I={isAny:!0};function M(r,...e){return Kt({event:"tk:fetchResult",args:{baseUrl:r,segments:e}})}function Qt(r){if(r)try{return JSON.parse(r)}catch{return}}var Xt=Object.defineProperty,er=Object.defineProperties,tr=Object.getOwnPropertyDescriptors,Be=Object.getOwnPropertySymbols,rr=Object.prototype.hasOwnProperty,ar=Object.prototype.propertyIsEnumerable,_e=(r,e,t)=>e in r?Xt(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ae=(r,e)=>{for(var t in e||(e={}))rr.call(e,t)&&_e(r,t,e[t]);if(Be)for(var t of Be(e))ar.call(e,t)&&_e(r,t,e[t]);return r},ne=(r,e)=>er(r,tr(e));class Ie extends _{async getRawReleasesData(){const e="https://api.comick.app/",[t]=await Promise.all([M(e,"chapter")]);if(!t)return;const a=t.map(n=>{var l,s;const{vol:i,chap:c,hid:o,lang:u,updated_at:p,md_comics:d}=n,h=typeof c=="string"&&!isNaN(+c)?+c:void 0;if(typeof h!="number")return;const v=(s=(l=d.md_covers)==null?void 0:l[0])==null?void 0:s.b2key;return{id:d.id+"",slug:d.slug,name:d.title,img:typeof v=="string"?`https://meo.comick.pictures/${v}`:void 0,chapters:[{slug:o,vol:typeof i=="string"&&!isNaN(+i)?+i:void 0,chap:h,lang:u,ts:new Date(p).valueOf()}]}}).filter(Boolean);return super.finalizeRawReleasesData({rawReleases:a})}async getRawTitleData(){var e,t,a,n;const l=await super.getRawTitleData();if(!l)return l;const s="https://api.comick.app/",[i]=await Promise.all([M(s,"comic",I,"chapters")]);if(!i)return l;const c=await nr(l.slug),o=[];i.chapters.forEach(d=>{const{vol:h,chap:v,hid:w,lang:f,updated_at:R}=d,m=typeof v=="string"&&!isNaN(+v)?+v:void 0;typeof m!="number"||o.some(b=>b.vol==h&&b.chap===m&&b.lang===f)||o.push({slug:w,vol:typeof h=="string"&&!isNaN(+h)?+h:void 0,chap:m,lang:f,ts:new Date(R).valueOf()})});const u=g("h1 ~ div.text-sm span:first-child|row:demographic"),p=u?(e=G(this.tags,[u]))==null?void 0:e[0]:void 0;return p&&!((t=l.tags)!=null&&t.includes(p))&&((a=l.tags)==null||a.push(p),(n=l.tags)==null||n.sort((d,h)=>d-h)),ne(ae({},l),{id:c,hasMoreChapters:i.chapters.length<i.total,chapters:E(o)})}async getRawReaderData(){var e;const t=await super.getRawReaderData();if(!t)return t;const a=await M("/_next/data/",I,"comic",I),n=(e=a?.comic)==null?void 0:e.id;return ne(ae({},t),{title:ne(ae({},t.title),{id:n?n+"":void 0})})}}Ie.specId="comick";async function nr(r){var e,t,a,n,l,s,i;const c=(e=document.querySelector("script#__NEXT_DATA__"))==null?void 0:e.textContent,o=c?Qt(c):void 0;if(((t=o?.query)==null?void 0:t.slug)===r){const d=(l=(n=(a=o?.props)==null?void 0:a.pageProps)==null?void 0:n.comic)==null?void 0:l.id;return d?d+"":void 0}const u=await M("/_next/data/",I,"comic",r,"covers.json"),p=(i=(s=u?.pageProps)==null?void 0:s.comic)==null?void 0:i.id;return p?p+"":void 0}var lr=Object.defineProperty,ir=Object.defineProperties,sr=Object.getOwnPropertyDescriptors,Ae=Object.getOwnPropertySymbols,or=Object.prototype.hasOwnProperty,ur=Object.prototype.propertyIsEnumerable,Ee=(r,e,t)=>e in r?lr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,le=(r,e)=>{for(var t in e||(e={}))or.call(e,t)&&Ee(r,t,e[t]);if(Ae)for(var t of Ae(e))ur.call(e,t)&&Ee(r,t,e[t]);return r},ie=(r,e)=>ir(r,sr(e));class Le extends _{resolveReaderSlug(e,t){return super.resolveReaderSlug(e,t).replace(/-page-\d{1,3}\.html$/,".html")}async getRawTitleData(){const e=await super.getRawTitleData();return e&&ie(le({},e),{chapters:ze(await this.getVM(),e.slug)})}async getRawReaderData(){const e=await super.getRawReaderData();if(!e)return e;const t=await this.getVM();return ie(le({},e),{imgs:cr(t,e.imgs[0]),title:ie(le({},e.title),{chapters:ze(t,e.title.slug)})})}getVM(){return this.getGlobalData([{attr:"angular"},{attr:"element",args:["__html__"]},{attr:"scope",args:[]},{attr:"vm"}])}}Le.specId="manga4life";function ze(r,e){var t,a;return((a=(t=r?.Chapters)!=null?t:r?.CHAPTERS)!=null?a:[]).map(n=>{const l=+n.Chapter.substring(1)/10;return{slug:`${e}-chapter-${l}.html`,chap:l,ts:new Date(n.Date).valueOf()}})}function cr(r,e){let t=e.split(".").slice(-1)[0];t=t.length>=3&&t.length<=4?t:"png";try{const a=r.CurChapter.Chapter.slice(1,-1),n=r.CurChapter.Chapter[r.CurChapter.Chapter.length-1],l=n!=="0"?`${a}.${n}`:a,s=`https://${r.CurPathName}/manga/${r.IndexName}/${l}-`;return r.Pages.map(i=>{const c=(i+"").padStart(3,"0");return`${s}${c}.${t}`})}catch{return[]}}var pr=Object.defineProperty,dr=Object.defineProperties,gr=Object.getOwnPropertyDescriptors,We=Object.getOwnPropertySymbols,hr=Object.prototype.hasOwnProperty,fr=Object.prototype.propertyIsEnumerable,qe=(r,e,t)=>e in r?pr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ke=(r,e)=>{for(var t in e||(e={}))hr.call(e,t)&&qe(r,t,e[t]);if(We)for(var t of We(e))fr.call(e,t)&&qe(r,t,e[t]);return r},Ue=(r,e)=>dr(r,gr(e));class Ve extends _{async getRawReleasesData(){const e="https://api.mangadex.org/",[t,a]=await Promise.all([M(e,"chapter"),M(e,"manga")]);if(!a||!t)return;const n={};a.data.forEach(({id:s,relationships:i})=>{var c;const o=i.find(({type:p})=>p==="cover_art"),u=(c=o?.attributes)==null?void 0:c.fileName;u&&(n[s]=`https://mangadex.org/covers/${s}/${u}`)});const l=t.data.map(({relationships:s,attributes:i,id:c})=>{const o=s.find(({type:d})=>d==="manga"),u=typeof i.volume=="string"?+i.volume:void 0,p=typeof i.chapter=="string"?+i.chapter:void 0;if(p)return{slug:o.id,name:Object.values(o.attributes.title)[0],img:n[o.id],chapters:[{slug:i.externalUrl||c,label:i.title||void 0,vol:u,chap:p,lang:i.translatedLanguage,ts:new Date(i.readableAt).valueOf()}]}}).filter(Boolean);return super.finalizeRawReleasesData({rawReleases:l})}async getRawTitleData(){var e,t,a;const n="https://api.mangadex.org/manga/",[l,s]=await Promise.all([M(n,I),M(n,I,"feed")]);if(!l||!s)return;const i=(a=(t=(e=s.data)==null?void 0:e.map)==null?void 0:t.call(e,u=>{const{attributes:p,id:d}=u;if(typeof p!="object"||typeof d!="string"||!d)return;const{externalUrl:h,title:v,volume:w,chapter:f,translatedLanguage:R}=p;return{slug:h||d,label:v||void 0,vol:typeof w=="string"?+w:void 0,chap:typeof f=="string"?+f:void 0,lang:R||"en",ts:new Date(p.readableAt).valueOf()}}).filter(u=>u?.chap!=null))!=null?a:[],{data:c}=l;if(!c)return;const o=Ge({data:c,entryTags:this.tags});if(o)return Ue(ke({},o),{chapters:E(i),hasMoreChapters:(s.total||0)>(s.limit||0)})}async getRawReaderData(){var e,t,a,n,l,s,i,c,o,u,p,d,h,v,w;const f="https://api.mangadex.org/",[R,m,b]=await Promise.all([M(f,"chapter",I),M(f,"at-home","server",I),M(f,"manga",I,"aggregate")]);if(!R||!m||!b)return;const O=R.data,{volume:$,chapter:S,externalUrl:P,translatedLanguage:y}=O.attributes||{},{baseUrl:x,chapter:{data:T,dataSaver:C,hash:Wr}}=m,ot=(t=(e=O.relationships)==null?void 0:e.find)==null?void 0:t.call(e,B=>B.type==="manga");if(!ot)return;const ut=Ge({data:ot,entryTags:this.tags});if(!ut||typeof b.volumes!="object")return;const A=Object.values(b.volumes).map(({volume:B,chapters:Vr})=>{const Gr=B==="none"||typeof B!="string"?void 0:+B;return Object.values(Vr).map(({id:Fr,chapter:ce})=>typeof ce!="string"||ce==="none"?void 0:{vol:Gr,chap:+ce,slug:Fr})}).flat().filter(Boolean).reverse();if(typeof S!="string"||S==="none"){if(A.length)return;A.push({chap:0,slug:O.id})}E(A);const ue=A.findIndex(B=>B.slug===O.id),Q=(n=(a=O.relationships)==null?void 0:a.find)==null?void 0:n.call(a,B=>B.type==="scanlation_group"),qr=x.endsWith("/")?x:x+"/",ct=!!((s=(l=localStorage.getItem("md"))==null?void 0:l.includes)!=null&&s.call(l,'"dataSaver":true')),kr=`${qr}${ct?"data-saver":"data"}/`,Ur=(u=(o=(c=(i=ct?C:T)!=null?i:[]).map)==null?void 0:o.call(c,B=>`${kr}${Wr}/${B}`))!=null?u:[];return{externalUrl:P,vol:typeof $=="string"?+$:void 0,inferVol:(p=A[ue])==null?void 0:p.inferVol,chap:+S||0,imgs:Ur,lang:y,slug:O.id,prevSlug:(d=A[ue+1])==null?void 0:d.slug,nextSlug:(h=A[ue-1])==null?void 0:h.slug,basePath:"/chapter/",groupName:(v=Q?.attributes)==null?void 0:v.name,groupUrl:(w=Q?.attributes)==null?void 0:w.website,title:Ue(ke({},ut),{chapters:A})}}resolveTitleSlug(e){var t;return(t=D(e))==null?void 0:t.split("/").filter(Boolean)[1]}}Ve.specId="mangadex";function Ge({data:r,entryTags:e}){var t,a,n,l,s;const{id:i,attributes:c,relationships:o}=r;if(!i||typeof i!="string"||typeof c!="object")return;const{title:u,availableTranslatedLanguages:p,altTitles:d,tags:h,contentRating:v}=c;if(typeof u!="object"||!Array.isArray(p))return;const w=Object.values(u)[0];if(!w||typeof w!="string")return;const f=vr(),R=(a=(t=p?.map)==null?void 0:t.call(p,y=>typeof y=="string"?y:void 0).filter(Boolean))!=null?a:[],m=R.filter(y=>y&&(!f||f.includes(y))),b=(n=d?.map)==null?void 0:n.call(d,y=>{const[[x,T]=[]]=Object.entries(y);return{lang:x,name:T}}),O=(l=o?.find)==null?void 0:l.call(o,y=>y.type==="cover_art"),$=(s=O?.attributes)==null?void 0:s.fileName,S=$?`https://mangadex.org/covers/${i}/${$}`:void 0,P=(h||[]).map(y=>{var x,T;return(T=(x=y?.attributes)==null?void 0:x.name)==null?void 0:T.en}).concat(v).filter(Boolean);return{url:`${location.origin}/title/${i}`,slug:i,name:w,altNames:b,langs:m.length>0?m:R,img:S,tags:G(e,P),isWebtoon:h?.some(y=>y.attributes.name.en==="Long Strip")}}function vr(){var r;const e=localStorage.getItem("md");if(e)try{const t=JSON.parse(e),a=(r=t?.userPreferences)==null?void 0:r.filteredLanguages;return a!=null&&a.length?a:void 0}catch{return}}var mr=(r=>(r[r.reading=1]="reading",r[r.paused=2]="paused",r[r.plan=3]="plan",r[r.completed=4]="completed",r[r.dropped=5]="dropped",r[r.deleted=6]="deleted",r))(mr||{}),se=(r=>(r.id="id",r.name="name",r.slug="slug",r))(se||{}),yr=(r=>(r[r.string=1]="string",r[r.number=2]="number",r[r.bool=3]="bool",r[r.selection=4]="selection",r))(yr||{}),wr=(r=>(r[r.pending=0]="pending",r[r.completed=1]="completed",r[r.offline=2]="offline",r[r.incompat=3]="incompat",r))(wr||{}),br=(r=>(r[r.releases=1]="releases",r[r.img=2]="img",r))(br||{});function Fe(r,e){const t=r[0]===e?r.substring(1):r;return t[t.length-1]===e?t.substring(0,t.length-1):t}var Rr=Object.defineProperty,Or=Object.defineProperties,Sr=Object.getOwnPropertyDescriptors,He=Object.getOwnPropertySymbols,$r=Object.prototype.hasOwnProperty,Pr=Object.prototype.propertyIsEnumerable,Je=(r,e,t)=>e in r?Rr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,L=(r,e)=>{for(var t in e||(e={}))$r.call(e,t)&&Je(r,t,e[t]);if(He)for(var t of He(e))Pr.call(e,t)&&Je(r,t,e[t]);return r},U=(r,e)=>Or(r,Sr(e));class Ye extends _{async getRawReleasesData(){const e=await super.getRawReleasesData();if(e)return U(L({},e),{siteMeta:Dr(this.spec.update,this.siteMeta)})}async getRawTitleData(){var e;const t=await super.getRawTitleData();if(!t)return;const a=z(location.pathname);let n;if((e=t.chapters)!=null&&e.length){const l=this.spec.title.chapter,s=document.querySelector(l.sel),i=D(g(l.url,{root:s}));i&&(n=z(i))}return U(L({},t),{siteMeta:K(this.siteMeta,{titleBase:a,readerBase:n})})}async getRawReaderData(){const e=await super.getRawReaderData();if(e)return U(L({},e),{siteMeta:K(this.siteMeta,{titleBase:z(D(e.title.url)),readerBase:z(location.pathname),idBase:Ze()}),title:U(L({},e.title),{id:await this.getReaderTitleId()})})}async getRawSearchData(){const e=await super.getRawSearchData();if(!e)return;const t=this.spec.search.title,a=document.querySelector(t.sel),n=g(t.url,{root:a});return U(L({},e),{siteMeta:K(this.siteMeta,{titleBase:z(D(n)),idBase:Ze()})})}async getReaderTitleId(){const e=await this.getGlobalData([{attr:"HISTORY"},{attr:"getStored",args:[]}]);if(!e||typeof e!="object")return;const t=Object.values(e).filter(Boolean);if(t.length)return t.sort((a,n)=>n.time-a.time),t[0].manga_ID}}Ye.specId="mangastream";function Dr(r,e){var t,a;if(!r)return;const n=U(L({},e),{updatePath:Fe(location.pathname,"/")}),l=r.title,s=(t=document.querySelector(l.sel))!=null?t:void 0;if(!s)return;const i=D(g(l.url,{root:s}));if(i===void 0)return;const c=(a=s.querySelector(l.chapter.sel))!=null?a:void 0;if(!c)return;const o=D(g(l.chapter.url,{root:c}));if(o!==void 0)return n.titleBase=z(i),n.readerBase=z(o),e.titleIdType===se.id&&(g(l.id,{root:s})||(e.titleIdType=se.name)),K(e,n)}function Ze(){return document.querySelector('link[rel="shortlink"][href*="/?p="]')?"?p=":void 0}function K(r,e){const t=Object.keys(e),a=L({},r);let n=!1;return t.forEach(l=>{const s=e[l];s!==r[l]&&(a[l]=s,n=!0)}),n?a:void 0}function z(r){return Fe(r,"/").split("/").slice(0,-1).join("/")}var jr=Object.defineProperty,xr=Object.defineProperties,Tr=Object.getOwnPropertyDescriptors,Ke=Object.getOwnPropertySymbols,Nr=Object.prototype.hasOwnProperty,Mr=Object.prototype.propertyIsEnumerable,Qe=(r,e,t)=>e in r?jr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,oe=(r,e)=>{for(var t in e||(e={}))Nr.call(e,t)&&Qe(r,t,e[t]);if(Ke)for(var t of Ke(e))Mr.call(e,t)&&Qe(r,t,e[t]);return r},Xe=(r,e)=>xr(r,Tr(e));class et extends _{async getRawReaderData(){const e=await super.getRawReaderData();if(!e)return e;let t=e.title.id;if(!t){const a=this.spec.reader.title;a.id&&await N(a.id.split("|")[0],{lazy:!0}),t=g(a.id)}return Xe(oe({},e),{title:Xe(oe({},e.title),{id:t,chapters:await Cr(t)})})}resolveTitleSlug(e){const t=super.resolveTitleSlug(e);if(!t)return;const a=t.lastIndexOf("-"),n=+t.substring(a+1);return a===-1||isNaN(n)||n<1e3?t:t.substring(0,a)}}et.specId="nettruyen";async function Cr(r){var e;if(!r)return[];const t=await fetch(`/Comic/Services/ComicService.asmx/ProcessChapterList?comicId=${r}`).then(a=>a.status===200?a.json():void 0).catch(()=>[]);return(e=t?.chapters)!=null&&e.length?E(t.chapters.map(a=>{const{name:n,url:l}=a,s=V(n);if(!(!s||!l))return oe({slug:D(l).split("/").filter(Boolean).slice(2).join("/")},s)})):[]}const Br=[Ne,Ie,Le,Ve,Ye,et];function tt(r){var e;const t=(e=Br.find(a=>a.specId===r.spec.id))!=null?e:Lt;return new t(r)}var _r=Object.defineProperty,Ir=Object.defineProperties,Ar=Object.getOwnPropertyDescriptors,rt=Object.getOwnPropertySymbols,Er=Object.prototype.hasOwnProperty,Lr=Object.prototype.propertyIsEnumerable,at=(r,e,t)=>e in r?_r(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,nt=(r,e)=>{for(var t in e||(e={}))Er.call(e,t)&&at(r,t,e[t]);if(rt)for(var t of rt(e))Lr.call(e,t)&&at(r,t,e[t]);return r},lt=(r,e)=>Ir(r,Ar(e));async function zr(r){var e,t;const{spec:a}=r;if(a){const n=(e=r.siteMeta)!=null?e:a.meta,l=r.type?[r.type]:it(n,a.generic);if(!l.length)return;const s=tt(lt(nt({},r),{spec:a,siteMeta:n}));return await q(l.map(i=>s.getRawPageByType(i)))}return await q(((t=r.genericSpecs)!=null?t:[]).map(n=>{const l=it(n.meta,n.generic);if(!l.length)return[];const s=tt(lt(nt({},r),{spec:n,siteMeta:n.meta}));return l.map(i=>s.getRawPageByType(i))}).flat())}function it(r,e){if(location.pathname==="/")return[];const{titleBase:t,readerBase:a}=r,n=location.pathname.split("/").filter(Boolean),l=st(n,a),s=st(n,t);if(l!==s)return l>s?[j.reader]:[j.title];if(l>0)return[j.reader,j.title];if(n.length===1){const i=[!a&&j.reader,!t&&j.title].filter(Boolean);if(i.length)return i}return e?[j.reader,j.title]:[]}function st(r,e){if(!e)return 0;const t=e.split("/").filter(Boolean);return r.length<=t.length?0:t.filter((a,n)=>r[n]===a||a==="{titleSlug}"||a==="{lang}").length}W.PageType=j,W.scrape=zr});
|
|
1
|
+
(function(k,z){typeof exports=="object"&&typeof module<"u"?z(exports):typeof define=="function"&&define.amd?define(["exports"],z):(k=typeof globalThis<"u"?globalThis:k||self,z(k._trackkun_={}))})(this,function(k){"use strict";function z(r){let e=!1;return new Promise((t,a)=>{Promise.all(r.map(async n=>{const l=await n;!e&&l&&(e=!0,t(l))})).then(()=>{e||t(void 0)})})}function ge(r,{removeTrailingSlash:e=!0}={}){if(!r)return;const t=e&&r.endsWith("/")?r.slice(0,-1):r;try{return new URL(t)}catch{return}}function P(r){var e,t;if(!(!r||typeof r!="string"))return r.startsWith("http://")||r.startsWith("https://")?(e=ge(r))==null?void 0:e.pathname:r.startsWith("//")?(t=ge(`https:${r}`))==null?void 0:t.pathname:r}const bt={text:Rt,attr:$t,"attr-contain":Ot,value:St,row:Dt};function d(r,e={}){if(!r)return;const{root:t=document.documentElement,returnAll:a,preProcess:n}=e,l=de(r);if(l.length>1){for(let p=0;p<l.length;p+=1){const g=d(l[p],e);if(g!=null&&g.length)return g}return}const[i,o]=r.split("|");if(!o)return;const u=(o!=null&&o.startsWith("[")&&o.endsWith("]")?o.substring(1,o.length-1).split(","):[o]).map(p=>{const g=p.indexOf(":"),h=g!==-1;return{action:h?p.substring(0,g):p,param:h?p.substring(g+1):""}}),s=i?Array.from(t.querySelectorAll(i)):[t];if(!s.length)return a?[]:void 0;n&&n(s);const c=[];for(const p of s)for(const g of u){const h=bt[g.action],v=h(p,g.param);if(v){if(a){c.push(v);break}return v}}return a?c:void 0}function Rt(r){return Array.from(r.childNodes).filter(e=>e.nodeType===3).map(e=>q(e.textContent)).filter(Boolean).join(" ").trim()||q(r.textContent)}function $t(r,e){return q(r.getAttribute(e))}function Ot(r,e){let t=r.getAttribute(e);if(!t){const a=r.getAttributeNames().find(n=>n.includes(e));a&&(t=r.getAttribute(a))}return q(t)}function de(r){const e=[],t=r.split("||").map(a=>a.trim()).filter(Boolean);return t.forEach((a,n)=>{if(a.includes("|")){e.push(a);return}const l=t[n+1];l&&(t[n+1]=`${a},${l}`)}),e}function St(r){return r.value}function Dt(r,e){var t,a,n,l;if(!e)return;const i=(t=q(r.textContent))==null?void 0:t.toLowerCase(),o=e.toLowerCase();if(!(i!==o&&i!==`${o}:`))return q((l=(a=r.nextElementSibling)==null?void 0:a.textContent)!=null?l:(n=r.nextSibling)==null?void 0:n.textContent)}function q(r){if(r)return r?.replace(/(\n|\t)/g," ").trim()||void 0}async function Q(r,e,t){const a=await t(()=>{r=0});if(a!==void 0)return a;if(!(r<=0))return await new Promise(n=>{setTimeout(async()=>{const l=await Q(r-1,e,t);n(l)},e)})}async function W(r,e,t=0){var a;const n=(a=e.root)!=null?a:document.documentElement;return Q(e.lazy===!0?200:0,100,()=>{var l;const i=e.all===!0?Array.from(n.querySelectorAll(r)):(l=n.querySelector(r))!=null?l:void 0;return(e.all?!(i!=null&&i.length):!i)?void 0:i})}const Pt=/(vol(ume|\.)?(\s*|-)(\d+))/i,xt=/(ch(ap(t(er)?|\.)?|\.)?|^#)(\s*|-)(\d+([_-~,.]\d+)?)/i,jt=/\d+([_-~,.]\d+)?/,Ct=/[_-~,]/;function G(r){var e;if(!r||!r)return;if(!isNaN(+r))return{chap:+r};const t=r.match(Pt),a=t!=null&&t[0]?r.replace(t[0],"").trim():r,n=a.match(xt),l=a.match(jt),i=(e=n?.[6])!=null?e:l?.[0];if(!i)return;const o=+i.replace(Ct,".");if(isNaN(o))return;const u=t?.[4];return{vol:u&&!isNaN(+u)?+u:void 0,chap:o}}function U(r){return r.sort((e,t)=>e.vol===void 0||t.vol===void 0?t.chap-e.chap:t.vol-e.vol||t.chap-e.chap),Tt(r)}function Tt(r){let e;for(let t=r.length-1;t>=0;t--){const a=r[t];a.vol!==void 0?e=a.vol:e!==void 0&&(a.inferVol=e)}return r}const Mt=[{regex:/(sec|giây)/,seconds:1},{regex:/(min|phút)/,seconds:60},{regex:/(hour|giờ)/,seconds:3600},{regex:/(day|ngày)/,seconds:86400},{regex:/(week|tuần)/,seconds:604800},{regex:/(month|tháng)/,seconds:2592e3},{regex:/(year|năm)/,seconds:31536e3}];function he(r){const e=r?.toLowerCase();if(!e||e.includes("now"))return Date.now();if(e.includes("yesterday"))return Date.now()-864e5;const t=new Date(e);if(t instanceof Date){const l=t.valueOf();if(!isNaN(l))return t.getHours()===0&&t.getMinutes()===0?Math.min(Date.now(),l+432e5):l}const a=Mt.find(l=>l.regex.test(e));if(!a)return;const n=e.split(" ").filter(Boolean);for(let l=0;l<n.length;l++){const i=n[l],o=i==="a"||i==="an"?1:+i;if(!o)continue;if(o<0)return;const u=Date.now()-o*a.seconds*1e3;return u>0?u:void 0}}function fe(r,e=location.origin){if(!r)return;const t=r.startsWith("//")?`${location.protocol}${r}`:r;return t.startsWith(e)?t.replace(e,""):t}function ve(r,e){if(!r)return"/";const t=r.replace("{titleSlug}",e),a=t.endsWith("/")?t:t+"/";return a.startsWith("/")?a:"/"+a}var It=Object.defineProperty,me=Object.getOwnPropertySymbols,Nt=Object.prototype.hasOwnProperty,Bt=Object.prototype.propertyIsEnumerable,ye=(r,e,t)=>e in r?It(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,_t=(r,e)=>{for(var t in e||(e={}))Nt.call(e,t)&&ye(r,t,e[t]);if(me)for(var t of me(e))Bt.call(e,t)&&ye(r,t,e[t]);return r};function we(r,e){var t,a;const n=[...e],l=[];let i=-1,o=-1;for(let s=0;s<r.length&&!(!n.length&&s>=10);s++){const c=_t({},r[s]),p=n.findIndex(v=>v.slug===c.slug&&v.name===c.name),g=p===-1?void 0:n.splice(p,1)[0],h=!g||((t=g.chapters[0])==null?void 0:t.chap)!==((a=c.chapters[0])==null?void 0:a.chap);p!==-1&&(o=s),h&&(i=s,c.changed=!0),l.push(c)}if(i===-1)return[];if(n.length&&n.length!==e.length){const s=Math.max(10,o+1);l.splice(s);for(let c=o+1;c<l.length;c++)l[c].changed=!1;return l}const u=Math.min(Math.max(i+1,10),Math.max(o+1,100));return l.slice(0,u)}var At=Object.defineProperty,Et=Object.defineProperties,Lt=Object.getOwnPropertyDescriptors,be=Object.getOwnPropertySymbols,kt=Object.prototype.hasOwnProperty,zt=Object.prototype.propertyIsEnumerable,Re=(r,e,t)=>e in r?At(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,qt=(r,e)=>{for(var t in e||(e={}))kt.call(e,t)&&Re(r,t,e[t]);if(be)for(var t of be(e))zt.call(e,t)&&Re(r,t,e[t]);return r},Wt=(r,e)=>Et(r,Lt(e));function $e(r,e){const t={};return r.forEach(a=>{Object.values(a.chapters.reduce((n,l)=>{const i=l.lang||e||"default";return n[i]||(n[i]=[]),n[i].push(l),n},{})).forEach(n=>{var l,i;const o=(i=(l=n[0])==null?void 0:l.lang)!=null?i:e,u=`${a.slug}:${o||""}`;t[u]?(t[u].chapters.push(...n),U(t[u].chapters)):t[u]=Wt(qt({},a),{lang:o})})}),Object.values(t)}var R=(r=>(r.title="title",r.reader="reader",r.releases="releases",r.chapters="chapters",r.search="search",r))(R||{});let Ut=class{constructor(e){this.methodsMap={[R.title]:()=>this.getRawTitleData(),[R.reader]:()=>this.getRawReaderData(),[R.releases]:()=>this.getRawReleasesData(),[R.search]:()=>this.getRawSearchData(),[R.chapters]:()=>this.getRawChaptersData()};var t;this.spec=e.spec,this.siteMeta=e.siteMeta,this.tags=e.tags,this.context=e.context,this.getGlobalData=(t=e.getGlobalData)!=null?t:Gt}async getRawSearchData(){throw new Error("Unimplemented")}async getRawPageByType(e,t=!1){const a=await this.methodsMap[e]();if(t&&!a)return;const n=location.origin+location.pathname;return{type:e,is404:Vt(this.spec),specId:this.spec.id,siteName:d(this.spec.name),url:n,data:a}}resolveReaderSlug(e,t){return t.startsWith(e)?t.replace(e,""):t}resolveTitleSlug(e){var t;if(typeof e!="string")return;const a=(t=P(e))==null?void 0:t.split("/").filter(Boolean);return!a||!a.length?e:a[a.length-1]}finalizeRawReleasesData(e){var t,a,n;const l=(a=(t=this.spec.releases)==null?void 0:t.title)!=null&&a.lang?this.siteMeta.defaultLang:void 0,i=$e(e.rawReleases,l);if(i.length)return{rawReleases:(n=this.context)!=null&&n.oldRawReleases?we(i,this.context.oldRawReleases):i}}getTagIdsFromNames(e){var t;if(!(e!=null&&e.length))return;const a=(t=this.normalizedTagsMap)!=null?t:this.normalizedTagsMap=Ft(this.tags),n=e.map(l=>a[ne(l)]).filter(Boolean);return n.length===0?void 0:Array.from(new Set(n)).sort((l,i)=>l-i)}};function Ft(r){const e={};return r.forEach(({id:t,name:a,altNames:n})=>{e[ne(a)]=t,n&&n.forEach(l=>{e[ne(l)]=t})}),e}function ne(r){const e=r.toLowerCase().replaceAll(" ","").replaceAll("-","");return e[e.length-1]==="s"?e.substring(0,e.length-1):e}function Vt(r){return r[404]&&document.querySelector(r[404])?!0:document.title.toLowerCase().includes("not found")}async function Gt(r){let e=window;const t={__html__:document.documentElement};for(let a=0;a<r.length;a++){const{attr:n,args:l}=r[a];if(!(n in e))return;e=l?e[n](...l.map(i=>{var o;return(o=t[i])!=null?o:i})):e[n]}return e===window?void 0:e}var Ht=Object.defineProperty,Jt=Object.defineProperties,Qt=Object.getOwnPropertyDescriptors,Y=Object.getOwnPropertySymbols,Oe=Object.prototype.hasOwnProperty,Se=Object.prototype.propertyIsEnumerable,De=(r,e,t)=>e in r?Ht(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,I=(r,e)=>{for(var t in e||(e={}))Oe.call(e,t)&&De(r,t,e[t]);if(Y)for(var t of Y(e))Se.call(e,t)&&De(r,t,e[t]);return r},_=(r,e)=>Jt(r,Qt(e)),Pe=(r,e)=>{var t={};for(var a in r)Oe.call(r,a)&&e.indexOf(a)<0&&(t[a]=r[a]);if(r!=null&&Y)for(var a of Y(r))e.indexOf(a)<0&&Se.call(r,a)&&(t[a]=r[a]);return t};class x extends Ut{async getRawReleasesData(){var e,t;if(!((t=(e=this.spec)==null?void 0:e.releases)!=null&&t.title))return;const a=this.spec.releases.title,{chapter:n}=a,l=Pe(a,["chapter"]),i=await W(l.sel,{lazy:!0,all:!0});if(!(i!=null&&i.length))return;const o=i.slice(0,100).map(s=>{const c=d(l.url,{root:s}),p=P(c),g=d(l.name,{root:s}),h=d(l.at,{root:s});if(!(!p||!g))return{titleEl:s,id:d(l.id,{root:s}),path:p,img:fe(d(l.img,{root:s})),name:g,lang:d(l.lang,{root:s}),at:h?he(h):void 0}}).filter(Boolean);if(!o.length)return;const u=await Promise.all(o.map(async s=>{var c;const p=s,{path:g,titleEl:h,lang:v,at:f}=p,y=Pe(p,["path","titleEl","lang","at"]),$=this.resolveTitleSlug(g),O=(c=await this.getChapters(n,{root:h,titleSlug:$}))!=null?c:[];return I({slug:$,chapters:v||f?O.map(b=>{var S,m;return _(I({},b),{lang:(S=b.lang)!=null?S:v,ts:(m=b.ts)!=null?m:f})}):O},y)}));return this.finalizeRawReleasesData({rawReleases:u})}async getRawTitleData(){var e,t;const a=this.spec.title;if(!a||a.sel&&!await W(a.sel,{lazy:!!a.lazy}))return;const n=d(a.name);if(!n)return;const l=this.resolveTitleSlug(location.pathname);if(!l)return;let i=(e=d(a.tags,{returnAll:!0}))!=null?e:[];i.length===1&&(i=i[0].split(",").map(s=>s.trim()).filter(Boolean));const o=d(a.type),u=d(a.langs,{returnAll:!0});return{id:d(a.id),url:location.origin+location.pathname,slug:l,name:n,langs:u!=null&&u.length?u:a.langs&&this.siteMeta.defaultLang?[this.siteMeta.defaultLang]:void 0,tags:this.getTagIdsFromNames([...i??[],...o?[o]:[]]),img:fe(d(a.img)),chapters:(t=await this.getChapters(a.chapter,{lazy:!0,titleSlug:l}))!=null?t:[]}}async getRawReaderData(){var e,t,a,n,l;const{spec:i,siteMeta:o}=this;if(!(i!=null&&i.reader)||i.generic&&!await x.isReaderPage(i.reader))return;const u=i.reader.title,s=document.querySelector(u.sel);if(!s)return;const c=d(u.name,{root:s}),p=d(u.url,{root:s}),g=this.resolveTitleSlug(p),h=d(u.img,{root:s});if(!c||!p||!g)return;const v=(t=await this.getChapters((e=i.reader)==null?void 0:e.chapter,{titleSlug:g}))!=null?t:[],f=(a=d(i.reader.label))==null?void 0:a.toLowerCase().replace(c.toLowerCase(),"");if(!f)return;const{vol:y,chap:$=0}=G(f)||{};let O;const b=(n=d(i.reader.img,{returnAll:!0,preProcess(B){const C=B.map(V=>+(V.getAttribute("height")||0)/+(V.getAttribute("width")||1));C.some(V=>V>2.5)?O=!0:C.filter(Boolean).length>Math.max(1,C.length-2)&&(O=!1)}}))!=null?n:[];if(!b.length)return;const S=ve(o.readerBase,g),m=o.readerBase.split("/").indexOf("{lang}"),D=m!==-1?location.pathname.substring(1).split("/")[m]:void 0,j=D?S.replace("{lang}",D):S,w=(l=D??d(i.reader.lang))!=null?l:i.reader.lang?this.siteMeta.defaultLang:void 0;return this.finalizeRawReaderData({isWebtoon:O,vol:y,chap:$,lang:w,slug:this.resolveReaderSlug(j,location.pathname),basePath:j,imgs:b,imgsLocator:i.reader.img,title:{id:d(u.id),url:p,slug:g,name:c,langs:w?[w]:void 0,img:h,chapters:v}},{prevSlug:this.findNeighborChapter({sel:i.reader.prev,basePath:j}),nextSlug:this.findNeighborChapter({sel:i.reader.next,basePath:j})})}async getRawChaptersData(){var e;const t=await this.getRawTitleData();if(!t)return;const a=(e=this.context)==null?void 0:e.lang,{chapters:n}=t;return{chapters:a?n.filter(l=>!l.lang||l.lang===a):n,title:_(I({},t),{chapters:[]}),hasMore:!1,asc:!1,total:n.length}}async getRawSearchData(){var e;const t=(e=this.spec.search)==null?void 0:e.title;if(!t)return;const{chapter:a}=t,n=[];return await Promise.all(Array.from(document.querySelectorAll(t.sel)).map(async l=>{var i;const o=d(t.url,{root:l}),u=P(o),s=d(t.name,{root:l}),c=this.resolveTitleSlug(u);!u||!s||!c||n.push({slug:c,name:s,chapters:(i=await this.getChapters(a,{root:l,titleSlug:c}))!=null?i:[]})})),n.length?{rawReleases:n}:void 0}async getChapters(e,{root:t=document.documentElement,titleSlug:a="",lazy:n=!0}){var l;if(!e)return;const i=[],o=await W(e.sel,{root:t,all:!0,lazy:n});if(!(o!=null&&o.length))return i;const u=(o??[]).map(f=>({id:d(e.id,{root:f}),label:d(e.label,{root:f}),url:d(e.url,{root:f}),at:d(e.at,{root:f})})),s=u.map(({label:f})=>G(f)),c=(l=s[1])==null?void 0:l.chap;!s[0]&&(c===void 0||c<=1)&&(s[0]={chap:0});const{readerBase:p}=this.siteMeta,g=ve(p,a),h=p.split("/").indexOf("{lang}"),v=h!==-1;return s.forEach((f,y)=>{var $;if(!f)return;const{id:O,url:b,at:S}=u[y],m=P(b);if(!m)return;const D=v?m?.substring(1).split("/")[h]:void 0,j=this.resolveReaderSlug(D?g.replace("{lang}",D):g,m);i.push(_(I({},f),{id:O,slug:j,lang:D,ts:he(S)||(($=i[i.length+1])==null?void 0:$.ts)||Date.now()}))}),U(i)}static async isReaderPage(e){const{sel:t,img:a}=e;if(!t||!a||!await W(t,{lazy:!!e.lazy}))return!1;const n=de(a).map(l=>l.split("|")[0]).join(",");return!!await W(n,{lazy:!0})}findNeighborChapter({sel:e,basePath:t}){const a=d(e);if(!a||a.startsWith("#")||a.startsWith("/#"))return;const n=P(a);return n?this.resolveReaderSlug(t,n):void 0}finalizeRawReaderData(e,{prevSlug:t,nextSlug:a}={}){var n;const l=(n=e.title)==null?void 0:n.chapters;if(!(l!=null&&l.length)){const c=G(t),p=G(a);return!c&&!p?e:_(I({},e),{prev:c?_(I({},c),{slug:t}):void 0,next:p?_(I({},p),{slug:a}):void 0})}let i,o,u,s;for(let c=0;c<l.length&&!(i&&(!t||u)&&!a&&s);c++){const p=l[c];!i&&(e.slug==p.slug||e.chap===p.chap&&(e.vol===p.vol||e.vol===void 0))?(i=p,o=c):!u&&t===p.slug?u=p:!s&&a===p.slug&&(s=p)}return o!==void 0&&(u!=null||(u=l[o+1]),s!=null||(s=l[o-1])),_(I({},e),{inferVol:i?.inferVol,prev:u,next:s})}}class xe extends x{resolveTitleSlug(e){var t;return(t=P(e))==null?void 0:t.split("/").filter(Boolean)[1]}}xe.specId="bato";function Yt(){return Math.random().toString(16).slice(2)}async function Kt({addListener:r,removeListener:e,transform:t,filter:a,handler:n,onTimeout:l,timeout:i,once:o}){return new Promise(u=>{r(p);const s=()=>o===!0&&e(p),c=i?setTimeout(()=>{s(),u(void 0),l?.()},i):void 0;async function p(g,...h){g=t?t(g):g,g!==void 0&&(!a||a(g,...h))&&(s(),u(g),n?.(g,...h),c&&clearTimeout(c))}})}var Xt=Object.defineProperty,je=Object.getOwnPropertySymbols,Zt=Object.prototype.hasOwnProperty,er=Object.prototype.propertyIsEnumerable,Ce=(r,e,t)=>e in r?Xt(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,tr=(r,e)=>{for(var t in e||(e={}))Zt.call(e,t)&&Ce(r,t,e[t]);if(je)for(var t of je(e))er.call(e,t)&&Ce(r,t,e[t]);return r};async function rr(r){const e=await Kt(tr({addListener:t=>window.addEventListener("message",t),removeListener:t=>window.removeEventListener("message",t)},r));return e?.data}async function ar(r){var e;const{receiverWindow:t,timeout:a,targetOrigin:n,event:l,args:i}=r,o={reqId:Yt(),event:l,args:i};(e=t||window)==null||e.postMessage(o,n??"*");const u=await rr({filter:s=>{var c;return((c=s?.data)==null?void 0:c.resId)===o.reqId},timeout:a??3e4,once:!0});return u?.result}const T={isAny:!0};function N(r,...e){return ar({event:"tk:fetchResult",args:{baseUrl:r,segments:e}})}function nr(r){if(r)try{return JSON.parse(r)}catch{return}}var lr=Object.defineProperty,ir=Object.defineProperties,or=Object.getOwnPropertyDescriptors,Te=Object.getOwnPropertySymbols,sr=Object.prototype.hasOwnProperty,cr=Object.prototype.propertyIsEnumerable,Me=(r,e,t)=>e in r?lr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,K=(r,e)=>{for(var t in e||(e={}))sr.call(e,t)&&Me(r,t,e[t]);if(Te)for(var t of Te(e))cr.call(e,t)&&Me(r,t,e[t]);return r},X=(r,e)=>ir(r,or(e));class Ie extends x{async getRawReleasesData(){let e=[];try{e=await(await fetch("https://api.comick.app/chapter?page=1&device-memory=8&order=hot&accept_erotic_content=true")).json()}catch{return}const t=[];return e.forEach(a=>{const{vol:n,chap:l,hid:i,lang:o,updated_at:u,md_comics:s}=a,c=typeof l=="string"&&!isNaN(+l)?+l:void 0;typeof c=="number"&&t.push({id:s.id+"",slug:s.slug,name:s.title,chapters:[{slug:i,vol:typeof n=="string"&&!isNaN(+n)?+n:void 0,chap:c,lang:o,ts:new Date(u).valueOf()}]})}),super.finalizeRawReleasesData({rawReleases:t})}async getRawTitleData(){var e,t,a,n,l,i;const o=await super.getRawTitleData();if(!o)return o;const u=await N("https://api.comick.app/","comic",T,"chapters");if(!u)return o;const s=await ur(o.slug),c=Ne(u),p=d("h1 ~ div.text-sm span:first-child|row:demographic"),g=p?(e=this.getTagIdsFromNames([p]))==null?void 0:e[0]:void 0;return g&&!((t=o.tags)!=null&&t.includes(g))&&((a=o.tags)==null||a.push(g),(n=o.tags)==null||n.sort((h,v)=>h-v)),X(K({},o),{id:s,hasMoreChapters:(l=c?.hasMore)!=null?l:!1,chapters:(i=c?.chapters)!=null?i:[]})}async getRawReaderData(){var e,t,a,n,l,i,o;const u=await super.getRawReaderData();if(!u)return u;const s=await N("/_next/data/",T,"comic",T),c=(e=s?.comic)==null?void 0:e.id,p=(n=(a=(t=s?.comic)==null?void 0:t.md_comic_md_genres)==null?void 0:a.map)==null?void 0:n.call(a,h=>{var v;return(v=h?.md_genre)==null?void 0:v.name}),g=(o=(i=(l=s?.comic)==null?void 0:l.md_covers)==null?void 0:i[0])==null?void 0:o.b2key;return X(K({},u),{title:X(K({},u.title),{id:c?c+"":void 0,tags:this.getTagIdsFromNames(p),img:typeof g=="string"?`https://meo.comick.pictures/${g}`:void 0})})}async getRawChaptersData(){var e;if(!((e=this.context)!=null&&e.rawId))return;const{rawId:t,lang:a="en",skip:n}=this.context,l=n?Math.floor(n/1e3)+1:void 0;try{const i=await fetch(`https://api.comick.app/comic/${t}/chapters?lang=${a}&limit=1000${l&&l>1?`&page=${l}`:""}`),o=Ne(await i.json());return o?X(K({},o),{lang:a,asc:!1}):void 0}catch{return}}}Ie.specId="comick";function Ne(r){var e;if(!Array.isArray(r?.chapters))return;const t=[];return r.chapters.forEach(a=>{const{vol:n,chap:l,hid:i,lang:o,updated_at:u}=a,s=typeof l=="string"&&!isNaN(+l)?+l:void 0;typeof s!="number"||t.some(c=>c.vol==n&&c.chap===s&&c.lang===o)||t.push({slug:i,vol:typeof n=="string"&&!isNaN(+n)?+n:void 0,chap:s,lang:o,ts:new Date(u).valueOf()})}),{chapters:U(t),total:(e=r.total)!=null?e:t.length,hasMore:r.total>r.limit}}async function ur(r){var e,t,a,n,l,i,o;const u=(e=document.querySelector("script#__NEXT_DATA__"))==null?void 0:e.textContent,s=u?nr(u):void 0;if(((t=s?.query)==null?void 0:t.slug)===r){const g=(l=(n=(a=s?.props)==null?void 0:a.pageProps)==null?void 0:n.comic)==null?void 0:l.id;return g?g+"":void 0}const c=await N("/_next/data/",T,"comic",r,"covers.json"),p=(o=(i=c?.pageProps)==null?void 0:i.comic)==null?void 0:o.id;return p?p+"":void 0}var pr=Object.defineProperty,gr=Object.defineProperties,dr=Object.getOwnPropertyDescriptors,Be=Object.getOwnPropertySymbols,hr=Object.prototype.hasOwnProperty,fr=Object.prototype.propertyIsEnumerable,_e=(r,e,t)=>e in r?pr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,le=(r,e)=>{for(var t in e||(e={}))hr.call(e,t)&&_e(r,t,e[t]);if(Be)for(var t of Be(e))fr.call(e,t)&&_e(r,t,e[t]);return r},ie=(r,e)=>gr(r,dr(e));class Ae extends x{resolveReaderSlug(e,t){return super.resolveReaderSlug(e,t).replace(/-page-\d{1,3}\.html$/,".html")}async getRawTitleData(){const e=await super.getRawTitleData();return e&&ie(le({},e),{chapters:Ee(await this.getVM(),e.slug),hasMoreChapters:!1})}async getRawReaderData(){const e=await super.getRawReaderData();if(!e)return e;const t=await this.getVM();return console.log("vm",t),this.finalizeRawReaderData(ie(le({},e),{imgs:vr(t,e.imgs[0]),title:ie(le({},e.title),{chapters:Ee(t,e.title.slug),hasMoreChapters:!1})}))}getVM(){return Q(40,50,()=>this.getGlobalData([{attr:"angular"},{attr:"element",args:["__html__"]},{attr:"scope",args:[]},{attr:"vm"}]))}}Ae.specId="manga4life";function Ee(r,e){var t,a;return((a=(t=r?.Chapters)!=null?t:r?.CHAPTERS)!=null?a:[]).sort((n,l)=>l.Chapter-n.Chapter).map(n=>{const l=+n.Chapter.substring(1)/10;return{slug:`${e}-chapter-${l}.html`,chap:l,ts:new Date(n.Date).valueOf()}})}function vr(r,e){let t=e.split(".").slice(-1)[0];t=t.length>=3&&t.length<=4?t:"png";try{const a=r.CurChapter.Chapter.slice(1,-1),n=r.CurChapter.Chapter[r.CurChapter.Chapter.length-1],l=n!=="0"?`${a}.${n}`:a,i=`https://${r.CurPathName}/manga/${r.IndexName}/${r.CurChapter.Directory?`${r.CurChapter.Directory}/`:""}${l}-`;return r.Pages.map(o=>{const u=(o+"").padStart(3,"0");return`${i}${u}.${t}`})}catch{return[]}}class mr{constructor(e){this.methodsMap={[R.title]:()=>this.getRawTitleData(),[R.reader]:()=>this.getRawReaderData(),[R.releases]:()=>this.getRawReleasesData(),[R.search]:()=>this.getRawSearchData(),[R.chapters]:()=>this.getRawChaptersData()};var t;this.spec=e.spec,this.siteMeta=e.siteMeta,this.tags=e.tags,this.context=e.context,this.getGlobalData=(t=e.getGlobalData)!=null?t:br}async getRawSearchData(){throw new Error("Unimplemented")}async getRawPageByType(e,t=!1){const a=await this.methodsMap[e]();if(t&&!a)return;const n=location.origin+location.pathname;return{type:e,is404:wr(this.spec),specId:this.spec.id,siteName:d(this.spec.name),url:n,data:a}}resolveReaderSlug(e,t){return t.startsWith(e)?t.replace(e,""):t}resolveTitleSlug(e){var t;if(typeof e!="string")return;const a=(t=P(e))==null?void 0:t.split("/").filter(Boolean);return!a||!a.length?e:a[a.length-1]}finalizeRawReleasesData(e){var t,a,n;const l=(a=(t=this.spec.releases)==null?void 0:t.title)!=null&&a.lang?this.siteMeta.defaultLang:void 0,i=$e(e.rawReleases,l);if(i.length)return{rawReleases:(n=this.context)!=null&&n.oldRawReleases?we(i,this.context.oldRawReleases):i}}getTagIdsFromNames(e){var t;if(!(e!=null&&e.length))return;const a=(t=this.normalizedTagsMap)!=null?t:this.normalizedTagsMap=yr(this.tags),n=e.map(l=>a[oe(l)]).filter(Boolean);return n.length===0?void 0:Array.from(new Set(n)).sort((l,i)=>l-i)}}function yr(r){const e={};return r.forEach(({id:t,name:a,altNames:n})=>{e[oe(a)]=t,n&&n.forEach(l=>{e[oe(l)]=t})}),e}function oe(r){const e=r.toLowerCase().replaceAll(" ","").replaceAll("-","");return e[e.length-1]==="s"?e.substring(0,e.length-1):e}function wr(r){return r[404]&&document.querySelector(r[404])?!0:document.title.toLowerCase().includes("not found")}async function br(r){let e=window;const t={__html__:document.documentElement};for(let a=0;a<r.length;a++){const{attr:n,args:l}=r[a];if(!(n in e))return;e=l?e[n](...l.map(i=>{var o;return(o=t[i])!=null?o:i})):e[n]}return e===window?void 0:e}var Rr=Object.defineProperty,$r=Object.defineProperties,Or=Object.getOwnPropertyDescriptors,Le=Object.getOwnPropertySymbols,Sr=Object.prototype.hasOwnProperty,Dr=Object.prototype.propertyIsEnumerable,ke=(r,e,t)=>e in r?Rr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ze=(r,e)=>{for(var t in e||(e={}))Sr.call(e,t)&&ke(r,t,e[t]);if(Le)for(var t of Le(e))Dr.call(e,t)&&ke(r,t,e[t]);return r},qe=(r,e)=>$r(r,Or(e));class We extends mr{resolveTitleSlug(e){var t;return(t=P(e))==null?void 0:t.split("/").filter(Boolean)[1]}async getRawReleasesData(){let e=[];try{e=(await(await fetch("https://api.mangadex.org/chapter?limit=96&offset=0&includes[]=manga&contentRating[]=safe&contentRating[]=suggestive&contentRating[]=erotica&contentRating[]=pornographic&order[readableAt]=desc")).json()).data}catch{return}const t=[];return e.forEach(({relationships:a,attributes:n,id:l})=>{const i=a.find(({type:s})=>s==="manga"),o=typeof n.volume=="string"?+n.volume:void 0,u=typeof n.chapter=="string"?+n.chapter:void 0;u&&t.push({slug:i.id,name:Object.values(i.attributes.title)[0],chapters:[{slug:n.externalUrl||l,vol:o,chap:u,lang:n.translatedLanguage,ts:new Date(n.readableAt).valueOf()}]})}),super.finalizeRawReleasesData({rawReleases:t})}async getRawTitleData(){var e,t,a;const n="https://api.mangadex.org/manga/",[l,i]=await Promise.all([N(n,T),N(n,T,"feed")]);if(!l||!i)return;const o=(a=(t=(e=i.data)==null?void 0:e.map)==null?void 0:t.call(e,c=>{const{attributes:p,id:g}=c;if(typeof p!="object"||typeof g!="string"||!g)return;const{externalUrl:h,title:v,volume:f,chapter:y,translatedLanguage:$}=p;return{slug:h||g,label:v||void 0,vol:typeof f=="string"?+f:void 0,chap:typeof y=="string"?+y:void 0,lang:$||"en",ts:new Date(p.readableAt).valueOf()}}).filter(c=>c?.chap!=null))!=null?a:[],{data:u}=l;if(!u)return;const s=Fe({data:u,getTagIdsFromNames:c=>this.getTagIdsFromNames(c)});if(s)return qe(ze({},s),{chapters:U(o),hasMoreChapters:(i.total||0)>(i.limit||0)})}async getRawReaderData(){var e,t,a,n,l,i,o,u,s,c,p,g,h,v;const f="https://api.mangadex.org/",[y,$,O]=await Promise.all([N(f,"chapter",T),N(f,"at-home","server",T),N(f,"manga",T,"aggregate")]);if(!y||!$||!O)return;const b=y.data,{volume:S,chapter:m,externalUrl:D,translatedLanguage:j}=b.attributes||{},{baseUrl:w,chapter:{data:B,dataSaver:C,hash:V}}=$,mt=(t=(e=b.relationships)==null?void 0:e.find)==null?void 0:t.call(e,M=>M.type==="manga");if(!mt)return;const yt=Fe({data:mt,getTagIdsFromNames:M=>this.getTagIdsFromNames(M)});if(!yt||typeof O.volumes!="object")return;const L=(a=Ue(y))!=null?a:[];(typeof m!="string"||m==="none")&&!L.length&&L.push({chap:0,slug:b.id});const pe=L.findIndex(M=>M.slug===b.id),ae=(l=(n=b.relationships)==null?void 0:n.find)==null?void 0:l.call(n,M=>M.type==="scanlation_group"),sa=w.endsWith("/")?w:w+"/",wt=!!((o=(i=localStorage.getItem("md"))==null?void 0:i.includes)!=null&&o.call(i,'"dataSaver":true')),ca=`${sa}${wt?"data-saver":"data"}/`,ua=(p=(c=(s=(u=wt?C:B)!=null?u:[]).map)==null?void 0:c.call(s,M=>`${ca}${V}/${M}`))!=null?p:[];return{externalUrl:D,vol:typeof S=="string"?+S:void 0,inferVol:(g=L[pe])==null?void 0:g.inferVol,chap:+m||0,imgs:ua,lang:j,slug:b.id,prev:L[pe+1],next:L[pe-1],basePath:"/chapter/",groupName:(h=ae?.attributes)==null?void 0:h.name,groupUrl:(v=ae?.attributes)==null?void 0:v.website,title:qe(ze({},yt),{chapters:L})}}async getRawChaptersData(){if(!this.context)return;const{titleSlug:e,lang:t="en"}=this.context;let a;try{const n=await fetch(`https://api.mangadex.org/manga/${e}/aggregate?translatedLanguage[]=${t}`);a=Ue(await n.json())}catch{return}if(a)return{chapters:a,lang:t,asc:!1,hasMore:!1,total:a.length}}}We.specId="mangadex";function Ue(r){if(typeof r.volumes!="object")return;const e=Object.values(r.volumes).map(({volume:t,chapters:a})=>{const n=t==="none"||typeof t!="string"?void 0:+t;return Object.values(a).map(({id:l,chapter:i})=>typeof i!="string"||i==="none"?void 0:{vol:n,chap:+i,slug:l})}).flat().filter(Boolean).reverse();return U(e)}function Fe({data:r,getTagIdsFromNames:e}){var t,a,n,l,i;const{id:o,attributes:u,relationships:s}=r;if(!o||typeof o!="string"||typeof u!="object")return;const{title:c,availableTranslatedLanguages:p,altTitles:g,tags:h,contentRating:v}=u;if(typeof c!="object"||!Array.isArray(p))return;const f=Object.values(c)[0];if(!f||typeof f!="string")return;const y=Pr(),$=(a=(t=p?.map)==null?void 0:t.call(p,w=>typeof w=="string"?w:void 0).filter(Boolean))!=null?a:[],O=$.filter(w=>w&&(!y||y.includes(w))),b=(n=g?.map)==null?void 0:n.call(g,w=>{const[[B,C]=[]]=Object.entries(w);return{lang:B,name:C}}),S=(l=s?.find)==null?void 0:l.call(s,w=>w.type==="cover_art"),m=(i=S?.attributes)==null?void 0:i.fileName,D=m?`https://mangadex.org/covers/${o}/${m}`:void 0,j=(h||[]).map(w=>{var B,C;return(C=(B=w?.attributes)==null?void 0:B.name)==null?void 0:C.en}).concat(v).filter(Boolean);return{url:`${location.origin}/title/${o}`,slug:o,name:f,altNames:b,langs:O.length>0?O:$,img:D,tags:e(j),isWebtoon:h?.some(w=>w.attributes.name.en==="Long Strip")}}function Pr(){var r;const e=localStorage.getItem("md");if(e)try{const t=JSON.parse(e),a=(r=t?.userPreferences)==null?void 0:r.filteredLanguages;return a!=null&&a.length?a:void 0}catch{return}}var xr=(r=>(r[r.reading=1]="reading",r[r.paused=2]="paused",r[r.plan=3]="plan",r[r.completed=4]="completed",r[r.dropped=5]="dropped",r[r.deleted=6]="deleted",r))(xr||{}),se=(r=>(r.id="id",r.name="name",r.slug="slug",r))(se||{}),jr=(r=>(r.blank="about:blank",r.title="meta.title",r.reader="meta.reader",r))(jr||{}),Cr=(r=>(r[r.string=1]="string",r[r.number=2]="number",r[r.bool=3]="bool",r[r.selection=4]="selection",r))(Cr||{}),Tr=(r=>(r[r.pending=0]="pending",r[r.completed=1]="completed",r[r.offline=2]="offline",r[r.incompat=3]="incompat",r))(Tr||{}),Mr=(r=>(r[r.releases=1]="releases",r[r.img=2]="img",r))(Mr||{});function Ve(r,e){const t=r[0]===e?r.substring(1):r;return t[t.length-1]===e?t.substring(0,t.length-1):t}var Ir=Object.defineProperty,Nr=Object.defineProperties,Br=Object.getOwnPropertyDescriptors,Ge=Object.getOwnPropertySymbols,_r=Object.prototype.hasOwnProperty,Ar=Object.prototype.propertyIsEnumerable,He=(r,e,t)=>e in r?Ir(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,A=(r,e)=>{for(var t in e||(e={}))_r.call(e,t)&&He(r,t,e[t]);if(Ge)for(var t of Ge(e))Ar.call(e,t)&&He(r,t,e[t]);return r},F=(r,e)=>Nr(r,Br(e));class Je extends x{async getRawReleasesData(){const e=await super.getRawReleasesData();if(e)return F(A({},e),{siteMeta:Er(this.spec.releases,this.siteMeta)})}async getRawTitleData(){var e;const t=await super.getRawTitleData();if(!t)return;const a=E(location.pathname);let n;if((e=t.chapters)!=null&&e.length){const l=this.spec.title.chapter,i=document.querySelector(l.sel),o=P(d(l.url,{root:i}));o&&(n=E(o))}return F(A({},t),{siteMeta:Z(this.siteMeta,{titleBase:a,readerBase:n})})}async getRawReaderData(){const e=await super.getRawReaderData();if(e)return F(A({},e),{siteMeta:Z(this.siteMeta,{titleBase:E(P(e.title.url)),readerBase:E(location.pathname),idBase:Qe()}),title:F(A({},e.title),{id:await this.getReaderTitleId()})})}async getRawSearchData(){const e=await super.getRawSearchData();if(!e)return;const t=this.spec.search.title,a=document.querySelector(t.sel),n=d(t.url,{root:a});return F(A({},e),{siteMeta:Z(this.siteMeta,{titleBase:E(P(n)),idBase:Qe()})})}async getReaderTitleId(){const e=await this.getGlobalData([{attr:"HISTORY"},{attr:"getStored",args:[]}]);if(!e||typeof e!="object")return;const t=Object.values(e).filter(Boolean);if(t.length)return t.sort((a,n)=>n.time-a.time),t[0].manga_ID}}Je.specId="mangastream";function Er(r,e){var t,a;if(!r)return;const n=F(A({},e),{releases:Ve(location.pathname,"/")}),l=r.title,i=(t=document.querySelector(l.sel))!=null?t:void 0;if(!i)return;const o=P(d(l.url,{root:i}));if(o===void 0)return;const u=(a=i.querySelector(l.chapter.sel))!=null?a:void 0;if(!u)return;const s=P(d(l.chapter.url,{root:u}));if(s!==void 0)return n.titleBase=E(o),n.readerBase=E(s),e.titleIdType===se.id&&(d(l.id,{root:i})||(e.titleIdType=se.name)),Z(e,n)}function Qe(){return document.querySelector('link[rel="shortlink"][href*="/?p="]')?"?p=":void 0}function Z(r,e){const t=Object.keys(e),a=A({},r);let n=!1;return t.forEach(l=>{const i=e[l];i!==r[l]&&(a[l]=i,n=!0)}),n?a:void 0}function E(r){return Ve(r,"/").split("/").slice(0,-1).join("/")}var Lr=Object.defineProperty,kr=Object.defineProperties,zr=Object.getOwnPropertyDescriptors,Ye=Object.getOwnPropertySymbols,qr=Object.prototype.hasOwnProperty,Wr=Object.prototype.propertyIsEnumerable,Ke=(r,e,t)=>e in r?Lr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ce=(r,e)=>{for(var t in e||(e={}))qr.call(e,t)&&Ke(r,t,e[t]);if(Ye)for(var t of Ye(e))Wr.call(e,t)&&Ke(r,t,e[t]);return r},Xe=(r,e)=>kr(r,zr(e));class Ze extends x{async getRawReaderData(){const e=await super.getRawReaderData();if(!e)return e;let t=e.title.id;if(!t){const a=this.spec.reader.title;a.id&&await W(a.id.split("|")[0],{lazy:!0}),t=d(a.id)}return Xe(ce({},e),{title:Xe(ce({},e.title),{id:t,chapters:await Ur(t),hasMoreChapters:!1})})}resolveTitleSlug(e){const t=super.resolveTitleSlug(e);if(!t)return;const a=t.lastIndexOf("-"),n=+t.substring(a+1);return a===-1||isNaN(n)||n<1e3?t:t.substring(0,a)}}Ze.specId="nettruyen";async function Ur(r){var e;if(!r)return[];const t=await fetch(`/Comic/Services/ComicService.asmx/ProcessChapterList?comicId=${r}`).then(a=>a.status===200?a.json():void 0).catch(()=>[]);return(e=t?.chapters)!=null&&e.length?U(t.chapters.map(a=>{const{name:n,url:l}=a,i=G(n);if(!(!i||!l))return ce({slug:P(l).split("/").filter(Boolean).slice(2).join("/")},i)})):[]}var Fr=Object.defineProperty,Vr=Object.defineProperties,Gr=Object.getOwnPropertyDescriptors,ee=Object.getOwnPropertySymbols,et=Object.prototype.hasOwnProperty,tt=Object.prototype.propertyIsEnumerable,rt=(r,e,t)=>e in r?Fr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,H=(r,e)=>{for(var t in e||(e={}))et.call(e,t)&&rt(r,t,e[t]);if(ee)for(var t of ee(e))tt.call(e,t)&&rt(r,t,e[t]);return r},J=(r,e)=>Vr(r,Gr(e)),at=(r,e)=>{var t={};for(var a in r)et.call(r,a)&&e.indexOf(a)<0&&(t[a]=r[a]);if(r!=null&&ee)for(var a of ee(r))e.indexOf(a)<0&&tt.call(r,a)&&(t[a]=r[a]);return t};class nt extends x{async getRawTitleData(){const e=await super.getRawTitleData();return e&&J(H({},e),{hasMoreChapters:!!ue()})}async getRawChaptersData(){var e,t;const a=await this.getRawTitleData();if(!(a!=null&&a.hasMoreChapters))return a;const n=(e=this.context)==null?void 0:e.findContinue;if(n){const g=await this.findContinueChapters({rawTitleData:a,chapter:n});return g?{chapters:g,title:J(H({},a),{chapters:[]})}:void 0}const l=(t=this.context)==null?void 0:t.skip,i=a,{chapters:o}=i,u=at(i,["chapters"]),s=o.length,c=l&&l>=s?Math.floor(l/s)+1:void 0;if(!c)return{chapters:o,title:J(H({},u),{chapters:[]}),hasMore:!!ue()};const p=await this.getChaptersByPage({page:c,titleSlug:a.slug});return{chapters:p??[],title:J(H({},u),{chapters:[]}),hasMore:!!ue(c),asc:!1,skip:l}}async findContinueChapters(e){var t=e,{rawTitleData:a,chapter:{chap:n},curPage:l=1,cacheChaptersByPage:i={}}=t,o=at(t,["rawTitleData","chapter","curPage","cacheChaptersByPage"]),u,s;const c=(u=i[l])!=null?u:a.chapters,p=c[c.length-1].chap<=n,g=(s=o.maxPage)!=null?s:Hr();if(p){if(c[0].chap>n){const m=[...c].reverse().find(D=>D.chap>n);return m?[m]:c.slice(0,1)}if(l<=1)return c.slice(0,1)}else if(l===g)return c.slice(-1);const h=a.chapters.length,v=Object.keys(i).map(m=>+m).sort((m,D)=>m-D),f=p?-1:1,y=v[v.indexOf(l)+f];if(y===l+f)return p?i[y].slice(-1).concat(c.slice(0,1)):c.slice(-1).concat(i[y].slice(0,1));const $=p?n-c[0].chap:c[0].chap-n,O=Math.floor($/h)+1,b=p?Math.max(O,(y??1)+1):Math.min(O,(y??g+1)-1,g),S=await this.getChaptersByPage({page:b,titleSlug:a.slug});if(S)return await this.findContinueChapters({rawTitleData:a,chapter:{chap:n},curPage:b,maxPage:g,cacheChaptersByPage:J(H({},i),{1:a.chapters,[b]:S})})}async getChaptersByPage({page:e,titleSlug:t}){const a=lt(e);if(!a)return;const n=this.spec.title.chapter,l=n.sel,i=document.querySelector(l),o=Q(100,30,()=>{const u=document.querySelector(l);if(u&&i!==u)return!0});return a.click(),await o,await this.getChapters(n,{lazy:!1,titleSlug:t})}}nt.specId="reaper";function ue(r=1){return lt(r+1)}function lt(r){const e=`span[wire\\:key="paginator-page-1-page${r}"] button,button[aria-label="Go to page ${r}"]`;return document.querySelector(e)}function Hr(){const r=Array.from(document.querySelectorAll('span[wire\\:key^="paginator-page-"]'));return r.length?+r[r.length-1].getAttribute("wire:key").split("-").slice(-1)[0].replace("page",""):1}var Jr=Object.defineProperty,Qr=Object.defineProperties,Yr=Object.getOwnPropertyDescriptors,it=Object.getOwnPropertySymbols,Kr=Object.prototype.hasOwnProperty,Xr=Object.prototype.propertyIsEnumerable,ot=(r,e,t)=>e in r?Jr(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,te=(r,e)=>{for(var t in e||(e={}))Kr.call(e,t)&&ot(r,t,e[t]);if(it)for(var t of it(e))Xr.call(e,t)&&ot(r,t,e[t]);return r},re=(r,e)=>Qr(r,Yr(e));class st extends x{async getRawTitleData(){var e,t;const a=await super.getRawTitleData();if(!a)return;const n=(e=d(".info-detail__row > .genre-btn,.info__right .stats__row:first-child|text",{returnAll:!0}))==null?void 0:e.map(l=>[l,...l.split(" ")]).flat();return ct(re(te({},a),{tags:(t=this.getTagIdsFromNames(n))!=null?t:[]}),".episode-header .episode-cnt")}async getRawReaderData(){const e=await super.getRawReaderData();if(e)return re(te({},e),{title:ct(re(te({},e.title),{url:`${location.origin}/series/${e.title.slug}/info`,tags:[]}),".episode-list .js-ep-cnt")})}async getRawChaptersData(){if(!this.context)return;const{rawId:e,skip:t}=this.context,a=1e3,n=t?Math.floor(t/1e3)+1:1;try{const l=await fetch(`/series/${e}/episodes?page=${n}&sort=NEWEST&max_limit=${a}`);return Zr(await l.json())}catch{return}}resolveTitleSlug(e){var t;if(!e)return;const a=e.split("/").filter(Boolean);return(t=a[1])!=null?t:a[0]}}st.specId="tapas";function ct(r,e){const t=ea(e)>20;return re(te({},r),{chapters:t?[]:r.chapters,hasMoreChapters:t})}function Zr(r){var e,t,a;const n=(e=r?.data)==null?void 0:e.episodes;if(!Array.isArray(n))return;const l=n.map(o=>{var u,s,c;return{chap:(u=o.pending_scene)!=null?u:o.scene,slug:o.id+"",ts:((c=(s=new Date(o.publish_date))==null?void 0:s.valueOf)==null?void 0:c.call(s))||void 0}}),i=(t=r?.data)==null?void 0:t.pagination;return{chapters:l,total:(a=i?.total)!=null?a:l.length,hasMore:!!(i!=null&&i.has_next)}}function ea(r){var e;const t=document.querySelector(r);return+(((e=t?.textContent)==null?void 0:e.trim().split(" ")[0])||0)}const ta=[xe,Ie,Ae,We,Je,Ze,nt,st];function ut(r){var e;const t=(e=ta.find(a=>a.specId===r.spec.id))!=null?e:x;return new t(r)}var ra=Object.defineProperty,aa=Object.defineProperties,na=Object.getOwnPropertyDescriptors,pt=Object.getOwnPropertySymbols,la=Object.prototype.hasOwnProperty,ia=Object.prototype.propertyIsEnumerable,gt=(r,e,t)=>e in r?ra(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,dt=(r,e)=>{for(var t in e||(e={}))la.call(e,t)&>(r,t,e[t]);if(pt)for(var t of pt(e))ia.call(e,t)&>(r,t,e[t]);return r},ht=(r,e)=>aa(r,na(e));async function oa(r){var e,t;const{spec:a}=r;if(a){const n=(e=r.siteMeta)!=null?e:a.meta,l=r.type?[r.type]:ft(n,a.generic);if(!l.length)return;const i=ut(ht(dt({},r),{spec:a,siteMeta:n}));return await z(l.map(o=>i.getRawPageByType(o)))}return await z(((t=r.genericSpecs)!=null?t:[]).map(n=>{const l=ft(n.meta,n.generic);if(!l.length)return[];const i=ut(ht(dt({},r),{spec:n,siteMeta:n.meta}));return l.map(o=>i.getRawPageByType(o,!0))}).flat())}function ft(r,e){if(location.pathname==="/")return[];const{titleBase:t,readerBase:a}=r,n=location.pathname.split("/").filter(Boolean),l=vt(n,a),i=vt(n,t);if(l!==i)return l>i?[R.reader]:[R.title];if(l>0)return[R.reader,R.title];if(n.length===1){const o=[!a&&R.reader,!t&&R.title].filter(Boolean);if(o.length)return o}return e?[R.reader,R.title]:[]}function vt(r,e){if(!e)return 0;const t=e.split("/").filter(Boolean),a=t.includes("{slug}"),n=r.length-t.length;return a&&n!==0||!a&&n<1?0:t.filter((l,i)=>r[i]===l||l==="{titleSlug}"||l==="{lang}"||l==="{slug}").length}k.PageType=R,k.scrape=oa});
|
package/init.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(){"use strict";function
|
|
1
|
+
(function(){"use strict";function P(n,e){let t;return()=>{t&&clearTimeout(t),t=setTimeout(()=>{n(),t=void 0},e)}}async function S({addListener:n,removeListener:e,transform:t,filter:a,handler:o,onTimeout:r,timeout:i,once:l}){return new Promise(s=>{n(O);const c=()=>l===!0&&e(O),d=i?setTimeout(()=>{c(),s(void 0),r?.()},i):void 0;async function O(u,...j){u=t?t(u):u,u!==void 0&&(!a||a(u,...j))&&(c(),s(u),o?.(u,...j),d&&clearTimeout(d))}})}var I=Object.defineProperty,p=Object.getOwnPropertySymbols,L=Object.prototype.hasOwnProperty,M=Object.prototype.propertyIsEnumerable,w=(n,e,t)=>e in n?I(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,T=(n,e)=>{for(var t in e||(e={}))L.call(e,t)&&w(n,t,e[t]);if(p)for(var t of p(e))M.call(e,t)&&w(n,t,e[t]);return n};async function v(n){const e=await S(T({addListener:t=>window.addEventListener("message",t),removeListener:t=>window.removeEventListener("message",t)},n));return e?.data}function k({event:n,filter:e,handler:t,senderWindow:a,targetOrigin:o}){v({filter:r=>{var i,l;return((i=r.data)==null?void 0:i.event)===n&&!!((l=r.data)!=null&&l.reqId)&&(!e||e(r))},handler:async r=>{const i=await t?.(r);(a||window).postMessage({resId:r.data.reqId,result:i},o??"*")}})}function W(){return Math.random().toString(16).slice(2)}async function y(n){var e;const{receiverWindow:t,timeout:a,targetOrigin:o,event:r,args:i}=n,l={reqId:W(),event:r,args:i};(e=t||window)==null||e.postMessage(l,o??"*");const s=await v({filter:c=>{var d;return((d=c?.data)==null?void 0:d.resId)===l.reqId},timeout:a??3e4,once:!0});return s?.result}async function f(n,e,t){const a=await t(()=>{n=0});if(a!==void 0)return a;if(!(n<=0))return await new Promise(o=>{setTimeout(async()=>{const r=await f(n-1,e,t);o(r)},e)})}var x=Object.defineProperty,g=Object.getOwnPropertySymbols,C=Object.prototype.hasOwnProperty,E=Object.prototype.propertyIsEnumerable,h=(n,e,t)=>e in n?x(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,m=(n,e)=>{for(var t in e||(e={}))C.call(e,t)&&h(n,t,e[t]);if(g)for(var t of g(e))E.call(e,t)&&h(n,t,e[t]);return n};const q=()=>{var n;return window.top&&window.top!=window&&((n=location.ancestorOrigins[0])==null?void 0:n.startsWith("chrome-extension://"))},b={delay:{loading:!0}};A();function A(){q()||(_(()=>{var a,o;y({event:"tk:spaNavigation",args:{}}),(o=(a=window.flutter_inappwebview)==null?void 0:a.callHandler)==null||o.call(a,"tk:spaNavigation",{})}),B(a=>{var o,r;y({event:"tk:titleChanged",args:{title:a}}),(r=(o=window.flutter_inappwebview)==null?void 0:o.callHandler)==null||r.call(o,"tk:titleChanged",a)}));let n=location.pathname,e=m({},b);async function t(a,o){const r=o.headers.get("Content-Type");if(!(r!=null&&r.includes("application/json"))){delete e[a];return}e[a]={res:o.clone()}}window.fetch=new Proxy(window.fetch,{apply:async(a,o,r)=>{var i,l;n!==location.pathname&&(n=location.pathname,e=m({},b));const[s,c]=r;return c!=null&&c.method&&((l=(i=c.method).toLowerCase)==null?void 0:l.call(i))!=="get"?await a.apply(o,r):(e[s]={loading:!0},delete e.delay,await a.apply(o,[s,c]).then(d=>(t(s,d),d)).catch(d=>{throw delete e[s],d}))}}),k({event:"tk:fetchResult",async handler(a){if(a.origin!==location.origin)return;const{baseUrl:o,segments:r}=a.data.args||{};return!Array.isArray(r)||typeof o!="string"?void 0:await R(()=>e,o,r.filter(i=>typeof i=="string"||typeof i?.isAny=="boolean"))}})}function N(n,e,t){const a=Object.keys(n).find(o=>H(o,e,t));return a?n[a]:void 0}function H(n,e,t){const a=n.replace(location.origin,""),o=e.replace(location.origin,"");if(!a.startsWith(o))return!1;const r=a.replace(o,"").split("?")[0].split("#")[0].split("/").filter(Boolean);return r.length===t.length&&t.every((i,l)=>i?.isAny||i===r[l])}function R(n,e,t){let a=15;return f(150,100,async o=>{const r=N(n(),e,t);if(!r){const i=Object.values(n());!(!i.length||i.some(l=>l.loading))&&!--a&&o();return}return await U(r)})}async function U(n){const{res:e,parsed:t,loading:a}=n;if(!a)return n.parsed=t??await e?.json().catch(async()=>JSON.parse(await e.text())).catch(()=>{}),delete n.res,n.parsed}function _(n){let e=location.pathname;const t=P(()=>{e!==location.pathname&&(e=location.pathname,n())},50),a=(o,r,i)=>(t(),o.apply(r,i));window.addEventListener("popstate",t),window.history.pushState=new Proxy(window.history.pushState,{apply:a}),window.history.replaceState=new Proxy(window.history.replaceState,{apply:a})}async function B(n){let e=document.title;setInterval(()=>{const t=document.title;t&&e!==t&&(e=t,n(t))},300)}})();
|
package/package.json
CHANGED
package/specs.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"404":"#content > .wrapper > .notf img","id":"mangastream","generic":true,"name":"meta[itemprop=\"name\"]|attr:content","meta":{"updatePath":"","titleBase":"series","readerBase":"","searchBase":"?s=","idBase":"?p=","titleIdType":"id","defaultLang":"en"},"update":{"title":{"sel":".listupd .utao .uta, .bixbox .bs.styletere","id":"a.series[rel]|attr:rel","name":"h4, .info .tt, .tt a|text","url":"a|attr:href","img":".imgu img, .limit img|attr-contain:src","chapter":{"sel":".luf ul li, .chapter-list > a, .chfiv > li","label":"a, .epxs|text","url":"a|attr:href || |attr:href","at":"a + span, .expdate, .newchtimeluffy|text"}}},"title":{"sel":"#chapterlist > ul","id":".bookmark[data-id]|attr:data-id","name":"h1.entry-title|text","img":".thumb img|attr-contain:src","type":".imptdt a[href*=\"type=\"]|text || .imptdt:first-of-type i|text","tags":".postbody .mgen > a|text","chapter":{"sel":"#chapterlist > ul > li","url":"a|attr:href","label":".chapternum|text","at":".chapterdate|text"}},"reader":{"sel":"#readerarea","id":".ctop option:selected|attr:data-id","label":"h1.entry-title|text","img":"#readerarea > p > img,#readerarea > img|attr-contain:src","title":{"sel":".headpost .allc","name":"a|text","url":"a|attr:href"},"prev":"a.ch-prev-btn:not(.disabled)|attr:href","next":"a.ch-next-btn:not(.disabled)|attr:href","chapter":{"sel":".ctop option:not([disabled]):not([value=\"\"])","id":"|attr:data-id","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":".listupd .bsx","name":".bigor .tt|text","url":"a|attr:href","img":".limit img|attr-contain:src"}}},{"404":".error-404.not-found","id":"madara","generic":true,"name":"a.logo|attr:title || meta[property=\"og:site_name\"]|attr:content","meta":{"updatePath":"","titleBase":"manga","readerBase":"manga/{titleSlug}","idBase":"?p=","searchBase":"?post_type=wp-manga&s=","defaultLang":"en","titleIdType":"id"},"update":{"title":{"sel":".page-listing-item .page-item-detail","id":"[data-post-id]|attr:data-post-id","name":"h3 a|text","url":"a|attr:href","img":"img|attr-contain:src","chapter":{"sel":".chapter-item","label":".chapter a|text","url":".chapter a|attr:href","at":".c-new-tag|attr:title || .post-on|text"}}},"title":{"lazy":true,"sel":".listing-chapters_wrap, #manga-chapters-holder","id":"#manga-chapters-holder|attr:data-id || .rating-post-id|attr:value","name":"h1|text","img":".summary_image .img-responsive|[attr:data-src,attr-contain:src]","tags":"a[rel=\"tag\"][href*=\"genre\"],a[rel=\"tag\"][href*=\"tag\"]|text","type":".post-content_item .summary-heading|row:type","chapter":{"sel":"li.wp-manga-chapter","url":"a|attr:href","label":"a|text","at":".c-new-tag|attr:title || .chapter-release-date i|text"}},"reader":{"sel":".entry-content .read-container","label":".breadcrumb li.active|text","img":".reading-content img|[attr:data-src,attr-contain:src]","title":{"sel":".breadcrumb li:nth-last-child(2) a","id":"#manga-reading-nav-head|attr:data-id","name":"|text","url":"|attr:href"},"prev":"a.btn.prev_page|attr:href","next":"a.btn.next_page|attr:href","chapter":{"sel":"#manga-reading-nav-head select.single-chapter-select > option:not([disabled])","label":"|text","url":"|attr:data-redirect"}},"search":{"title":{"sel":".c-tabs-item__content","name":"h3 a|text","url":"a|attr:href","img":".tab-thumb img|attr-contain:src","chapter":{"sel":".tab-meta","label":".chapter a|text","url":".chapter a|attr:href","at":".c-new-tag|attr:title || .post-on|text"}}}},{"404":".elapi > a[href*=\"/search?q=\"]","id":"mangahub","name":".navbar-brand img.logo|attr:alt","meta":{"updatePath":"","titleBase":"manga","readerBase":"chapter/{titleSlug}","searchBase":"search?q=","defaultLang":"en","titleIdType":"slug"},"update":{"title":{"sel":".list-group-item .media","name":"h4.media-heading a|text","img":".media-left img|attr-contain:src","url":".media-heading a|attr:href","at":".media-heading .small|text","chapter":{"sel":".media-body > a","label":"|text","url":"|attr:href"}}},"title":{"sel":"#chapters-tab .tab-content","name":"#mangadetail h1|text","img":"#mangadetail img.manga-thumb|attr-contain:src","tags":"#mangadetail a.genre-label|text","chapter":{"sel":"#chapters-tab li.list-group-item","label":"a > span:first-child > span:first-child|text","url":"a|attr:href","at":"small|text"}},"reader":{"sel":"#mangareader","label":"h3|text","img":"#mangareader div img[alt]|attr-contain:src","prev":".chapter-pager .previous a[href*=\"/chapter/\"]|attr:href","next":".chapter-pager .next a[href*=\"/chapter/\"]|attr:href","title":{"sel":"h3 a","name":"|text","url":"|attr:href"},"chapter":{"sel":".pager-dropdown .dropdown-menu > li > a","label":"|text","url":"|attr:href"}},"search":{"title":{"sel":".media-manga","name":"h4 a|text","img":".media-left img|attr-contain:src","url":"h4 a|attr:href","chapter":{"sel":".media-body","label":"a[href*=\"/chapter/\"]|text","url":"a[href*=\"/chapter/\"]|attr:href"}}}},{"404":"#content > .wrapper > .notf img","id":"manhwafreak","name":"meta[itemprop=\"name\"],meta[property=\"og:site_name\"]|attr:content","meta":{"updatePath":"","titleBase":"manga","readerBase":"","searchBase":"?s=","idBase":"?p=","defaultLang":"en","titleIdType":"name"},"update":{"title":{"sel":".lastest .lastest-serie","name":".lastest-title a|text","img":".img img|attr-contain:src","url":"a|attr:href","chapter":{"sel":".lastest-chap > a","label":"li|text","url":"|attr:href","at":"li span|text"}}},"title":{"sel":".series + .chapters .chapter-li","name":".series h1.title|text","img":".series .info img|attr-contain:src","tags":"#info > .left > div > p:first-child|row:genre(s)","type":"#info > .left > div > p:first-child|row:type","chapter":{"sel":".chapter-li > a","label":".chapter-info p|text","url":"|attr:href","at":".chapter-info p:nth-child(2)|text"}},"reader":{"sel":"#readerarea","label":"h2.entry-title|text","img":"#readerarea img.ts-main-image[data-index]|[attr:data-src,attr-contain:src]","prev":"a.ch-prev-btn:not(.disabled)|attr:href","next":"a.ch-next-btn:not(.disabled)|attr:href","title":{"sel":".breadcrumb > ul > li:nth-child(3) a","name":"span|text","url":"|attr:href"},"chapter":{"sel":".ctop select#chapter option:not([disabled]):not([value=\"\"])","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":".listupd .lastest-serie","name":".lastest-title|text","url":"a|attr:href","img":"img.ts-post-image|attr-contain:src","chapter":{"sel":".lastest-chap > a","label":"li|text","url":"|attr:href","at":"li span|text"}}}},{"404":".error-404.not-found","id":"nettruyen","name":"meta[property=\"og:site_name\"]|attr:content","meta":{"updatePath":"","titleBase":"truyen-tranh","readerBase":"truyen-tranh/{titleSlug}","searchBase":"tim-truyen?keyword=","defaultLang":"vi","titleIdType":"id"},"update":{"title":{"sel":".items > .row > .item","id":".comic-item|attr:data-id","name":"h3 a|text","img":".image img|attr-contain:src","url":"h3 a|attr:href","chapter":{"sel":".chapter","label":"a|text","url":"a|attr:href","at":".time|text"}}},"title":{"sel":"#nt_listchapter nav > ul","id":".rating .star[data-id],.follow-link[data-id]|attr:data-id","name":"#item-detail h1.title-detail|text","img":"#item-detail .detail-info img|attr-contain:src","tags":".kind a[href*=\"/tim-truyen/\"]|text","chapter":{"sel":"#nt_listchapter nav > ul > li.row","label":".chapter a|text","url":".chapter a|attr:href","at":".small|text"}},"reader":{"sel":".reading .reading-detail","label":"a.itemcrumb.active > span[itemprop=\"name\"]|text","img":".reading-detail > .page-chapter > img,.reading-detail > img|[attr:data-original,attr-contain:src]","prev":"a.prev.a_prev:not(.disabled)|attr:href","next":"a.next.a_next:not(.disabled)|attr:href","title":{"sel":"h1.txt-primary a","id":".follow-link[data-id]|attr:data-id","name":"|text","url":"|attr:href"}},"search":{"title":{"sel":".items > .row > .item","name":"h3 a|text","img":".image img|attr-contain:src","url":"h3 a|attr:href"}}},{"id":"manga4life","name":"#Nav .LogoBox a|attr:title","meta":{"updatePath":"","titleBase":"manga","readerBase":"read-online","searchBase":"search/?name=","defaultLang":"en","titleIdType":"slug"},"update":{"title":{"sel":".BoxBody.LatestChapters .Chapter","name":".Image > a|attr:title","img":".Image > a img|attr-contain:src","url":".Image > a|attr:href","chapter":{"sel":".Label > a","label":".ChapterLabel|text","url":"|attr:href","at":".DateLabel|text"}}},"title":{"sel":".BoxBody div.list-group[ng-if^=\"vm.Chapters\"]","name":".BoxBody h1|text","img":"meta[property=\"og:image\"],meta[property=\"twitter:image:src\"]|attr:content","tags":"a[href*=\"search/?genre=\"]|text","type":"a[href*=\"search/?type=\"]|text"},"reader":{"sel":"#TopPage.ImageGallery","label":"button[data-target=\"#ChapterModal\"]|text","img":".ImageGallery img.img-fluid|attr:ng-src","title":{"sel":".DesktopNav a","name":"|text","url":"|attr:href"}},"search":{"title":{"sel":".SearchFilterNav + .row > div[ng-repeat^=\"Series\"]","name":"div:nth-child(2) a.SeriesName|text","img":"img|attr-contain:src","url":"a|attr:href"}}},{"id":"mangadex","name":"meta[property='og:site_name']|attr:content","meta":{"updatePath":"titles/latest","titleBase":"title","readerBase":"chapter","searchBase":"titles?q=","defaultLang":"en","multiLang":true,"titleIdType":"slug"},"fetchOverrides":[{"type":"updates","match":"^api\\.mangadex\\.org\\/(chapter|manga)$","params":[{"key":"limit","value":"96"},{"key":"contentRating[]","value":"pornographic"}]},{"type":"chapters","match":"^api\\.mangadex\\.org\\/manga\\/.+\\/feed$","params":[{"id":"limit","key":"limit","value":"500"},{"id":"lang","key":"translatedLanguage[]"}]}]},{"id":"comick","name":"meta[property=\"og:site_name\"],meta[name=\"application-name\"]|attr:content","meta":{"home":"home","updatePath":"home","titleBase":"comic","readerBase":"comic/{titleSlug}","searchBase":"search?q=","defaultLang":"en","multiLang":true,"titleIdType":"id"},"fetchOverrides":[{"type":"updates","match":"^api\\.comick\\.app\\/chapter$","params":[{"key":"order","value":"new"},{"key":"accept_erotic_content","value":"true"}]},{"type":"chapters","match":"^api\\.comick\\.app\\/comic\\/.+\\/chapters$","params":[{"id":"limit","key":"limit","value":"1000"},{"id":"lang","key":"lang"}]}],"update":{"title":{"sel":"#updates-container div[title]","name":"|attr:title","img":"img|attr-contain:src","url":"a[href^=\"/comic/\"]|attr:href","chapter":{"sel":"a:last-child","label":"div:first-child|text","url":"|attr:href","at":"div:nth-child(2)|text"}}},"title":{"sel":"#chapter-header ~ div table > tbody","name":"h1|text","img":"a[href$=\"/covers\"] > img|attr-contain:src","langs":"#chapter-header + div select option:not([value=\"\"]):not([value=\"all\"])|attr:value","tags":"table a.link[href^=\"/search?genres=\"]|text","type":"h1 ~ div.text-sm span:first-child|row:origination"},"reader":{"lazy":true,"sel":".images-reader-container","label":"select:first-of-type option[selected]|text","img":".images-reader-container img|attr-contain:src","title":{"sel":"div > a[href*=\"/comic/\"]","name":"|text || img[alt]|attr:alt","url":"|attr:href","img":"img|attr-contain:src"},"lang":"select:nth-child(2)|value","prev":".images-reader-container a:first-child[href^=\"/comic/\"]:not(:last-child)|attr:href","next":".images-reader-container a:last-child[href^=\"/comic/\"]|attr:href","chapter":{"sel":"select:first-of-type option:not([disabled]):not([value=\"\"])","label":"|text","url":"|attr:value"}}},{"id":"bato","name":".brand img[alt]|attr:alt","meta":{"updatePath":"","titleBase":"series","readerBase":"chapter","searchBase":"search?word=","defaultLang":"en","titleIdType":"slug"},"update":{"title":{"sel":"#series-list > .item","name":"a.item-title|text","img":".item-cover img|attr-contain:src","url":"a.item-title|attr:href","lang":"em[data-lang]|attr:data-lang","chapter":{"sel":".item-volch","label":"a|text","url":"a|attr:href","at":"i|text"}}},"title":{"sel":".detail-set ~ .episode-list","name":"h3.item-title a|text","img":".attr-cover > img|attr-contain:src","langs":".title-set em[data-lang]|attr:data-lang","tags":".attr-main .attr-item .text-muted|row:genres","chapter":{"sel":".episode-list > .main > .item","label":"a.chapt > b|text","url":"a.chapt|attr:href","at":".extra > i|text"}},"reader":{"sel":"#viewer","label":"title|text","img":"img.page-img|attr-contain:src","title":{"sel":"h3.nav-title a","name":"|text","url":"|attr:href"},"lang":"h3.nav-title em[data-lang]|attr:data-lang","prev":".nav-prev > a[href^=\"/chapter/\"]|attr:href","next":".nav-next > a[href^=\"/chapter/\"]|attr:href","chapter":{"sel":".nav-epis > select option:not([disabled]):not([value=\"\"])","label":"|text","url":"|attr:value"}}},{"404":"#error > .attention","id":"mangago","name":"#logo_div|attr:title || meta[property=\"og:site_name\"]|attr:content","meta":{"updatePath":"list/latest","titleBase":"read-manga","readerBase":"read-manga/{titleSlug}","searchBase":"r/l_search/?name=","defaultLang":"en","titleIdType":"slug"},"update":{"title":{"sel":"#search_list > li .box","name":"a.thm-effect|attr:title","img":"a.thm-effect img|attr-contain:src","url":"a.thm-effect|attr:href","chapter":{"sel":"a.chico","label":"|text","url":"|attr:href"}}},"title":{"sel":"#chapter_table","name":".w-title h1|text","img":".article .cover img|attr-contain:src","tags":".manga_right a[href*=\"/genre/\"]|text","chapter":{"sel":"#chapter_table tbody tr","label":"h4 a b|text","url":"h4 a|attr:href","at":"td:last-child|text"}},"reader":{"sel":"#pic_container","label":"#navi h3 span:last-child|text","img":"#pic_container img[id^=\"page\"]|attr-contain:src","title":{"sel":"#navi a#series","name":"|text","url":"|attr:href"},"chapter":{"sel":"ul.dropdown-menu.chapter > li > a","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":"#search_list > li .box","name":"a.thm-effect|attr:title","img":"a.thm-effect img|attr-contain:src","url":"a.thm-effect|attr:href","chapter":{"sel":"a.chico","label":"|text","url":"|attr:href"}}}},{"404":".nf-large + .nf-desc + a[href=\"/home\"]","id":"kakalot","name":"meta[property=\"og:site_name\"]|attr:content","meta":{"home":"home","updatePath":"home","titleBase":"","readerBase":"read/{titleSlug}/{lang}","searchBase":"search?keyword=","defaultLang":"en","multiLang":true,"titleIdType":"id"},"update":{"title":{"sel":"#latest-chap .inner > .item","id":".item-info h3|attr:data-id","name":".item-info h3 a|text","img":".item-poster img|attr-contain:src","url":"a|attr:href","chapter":{"sel":".chapter-list > .cl-item","label":"a.chapter-name|text","url":"a|attr:href","at":".time|text"}}},"title":{"lazy":true,"sel":"#chapt-list .cl-header","id":"#main|attr:data-id","name":".detail-box h3.manga-name|text","img":".detail-box .manga-poster-img|attr-contain:src","tags":".detail-box .line-content a[href*=\"/genre/\"]|text","langs":"#chap-lang .lang-item|attr:data-code","chapter":{"sel":"#chapt-list .reading-list > .item","label":"a.chapter-name|text","url":"a.chapter-name|attr:href","at":".item-time|text"}},"reader":{"sel":"#reading","label":".breadcrumb-item.active|text","img":"#list-image .card-wrap[data-url]|attr:data-url","title":{"sel":".breadcrumb-item:nth-child(2) a","id":"#reading|attr:data-manga-id","name":"|text","url":"|attr:href"},"chapter":{"sel":".kbreadcrumb + .reading-option option.reading-item","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":".manga-list > .inner > .item","name":".manga-name a|attr:title","img":".manga-poster img|attr-contain:src","url":".manga-name a|attr:href","chapter":{"sel":".latest-chapter .chapter-name","label":"|text","url":"|attr:href"}}}},{"id":"reaper","name":"nav a img[alt]|attr:alt","meta":{"updatePath":"latest/comics","titleBase":"comics","readerBase":"comics/{titleSlug}/chapters","searchBase":"?s=","defaultLang":"en","titleIdType":"name"},"update":{"title":{"sel":"main h2 + div .grid.grid-cols-1 > div","img":"a img|attr-contain:src","name":"p a|text","url":"a|attr:href","chapter":{"sel":"p + div > a","label":"|text","url":"|attr:href","at":"p|text"}}},"title":{"sel":"div > ul[role=\"list\"]:first-child","name":"h1|text","img":"main .container img[alt]","chapter":{"sel":"div > ul[role=\"list\"]:first-child li[wire\\:key^=\"comic-chapter-list\"] a","label":"p|text","url":"|attr:href","at":"div:last-child > p|text"}},"reader":{"sel":"","label":"title|text","img":"main nav ~ img.max-w-full|attr-contain:src","prev":"main nav:first-of-type > div:first-child a|attr:href","next":"main nav:first-of-type > div:last-child a:last-child:not(:first-child)|attr:href","title":{"sel":"body","name":"main p|text","url":"main nav:first-of-type > div:last-child a:first-child|attr:href"}}}]
|
|
1
|
+
[{"404":"#content > .wrapper > .notf img","id":"mangastream","generic":true,"name":"meta[itemprop=\"name\"]|attr:content","meta":{"releases":"","titleBase":"series","readerBase":"","searchBase":"?s=","idBase":"?p=","titleIdType":"id","defaultLang":"en"},"releases":{"title":{"sel":".listupd .utao .uta, .bixbox .bs.styletere","id":"a.series[rel]|attr:rel","name":"h4, .info .tt, .tt a|text","url":"a|attr:href","img":".imgu img, .limit img|attr-contain:src","chapter":{"sel":".luf ul li, .chapter-list > a, .chfiv > li","label":"a, .epxs|text","url":"a|attr:href || |attr:href","at":"a + span, .expdate, .newchtimeluffy|text"}}},"title":{"sel":"#chapterlist > ul","id":".bookmark[data-id]|attr:data-id","name":"h1.entry-title|text","img":".thumb img|attr-contain:src","type":".imptdt a[href*=\"type=\"]|text || .imptdt:first-of-type i|text","tags":".postbody .mgen > a|text","chapter":{"sel":"#chapterlist > ul > li","url":"a|attr:href","label":".chapternum|text","at":".chapterdate|text"}},"reader":{"sel":"#readerarea","id":".ctop option:selected|attr:data-id","label":"h1.entry-title|text","img":"#readerarea > p > img,#readerarea > img|attr-contain:src","title":{"sel":".headpost .allc","name":"a|text","url":"a|attr:href"},"prev":"a.ch-prev-btn:not(.disabled)|attr:href","next":"a.ch-next-btn:not(.disabled)|attr:href","chapter":{"sel":".ctop option:not([disabled]):not([value=\"\"])","id":"|attr:data-id","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":".listupd .bsx","name":".bigor .tt|text","url":"a|attr:href","img":".limit img|attr-contain:src"}}},{"404":".error-404.not-found","id":"madara","generic":true,"name":"a.logo|attr:title || meta[property=\"og:site_name\"]|attr:content","meta":{"releases":"","titleBase":"manga","readerBase":"manga/{titleSlug}","idBase":"?p=","searchBase":"?post_type=wp-manga&s=","defaultLang":"en","titleIdType":"id"},"releases":{"title":{"sel":".page-listing-item .page-item-detail","id":"[data-post-id]|attr:data-post-id","name":"h3 a|text","url":"a|attr:href","img":"img|attr-contain:src","chapter":{"sel":".chapter-item","label":".chapter a|text","url":".chapter a|attr:href","at":".c-new-tag|attr:title || .post-on|text"}}},"title":{"lazy":true,"sel":".listing-chapters_wrap, #manga-chapters-holder","id":"#manga-chapters-holder|attr:data-id || .rating-post-id|attr:value","name":"h1|text","img":".summary_image .img-responsive|[attr:data-src,attr-contain:src]","tags":"a[rel=\"tag\"][href*=\"genre\"],a[rel=\"tag\"][href*=\"tag\"]|text","type":".post-content_item .summary-heading|row:type","chapter":{"sel":"li.wp-manga-chapter","url":"a|attr:href","label":"a|text","at":".c-new-tag|attr:title || .chapter-release-date i|text"}},"reader":{"sel":".entry-content .read-container","label":".breadcrumb li.active|text","img":".reading-content img|[attr:data-src,attr-contain:src]","title":{"sel":".breadcrumb li:nth-last-child(2) a","id":"#manga-reading-nav-head|attr:data-id","name":"|text","url":"|attr:href"},"prev":"a.btn.prev_page|attr:href","next":"a.btn.next_page|attr:href","chapter":{"sel":"#manga-reading-nav-head select.single-chapter-select > option:not([disabled])","label":"|text","url":"|attr:data-redirect"}},"search":{"title":{"sel":".c-tabs-item__content","name":"h3 a|text","url":"a|attr:href","img":".tab-thumb img|attr-contain:src","chapter":{"sel":".tab-meta","label":".chapter a|text","url":".chapter a|attr:href","at":".c-new-tag|attr:title || .post-on|text"}}}},{"404":".elapi > a[href*=\"/search?q=\"]","id":"mangahub","meta":{"releases":"","titleBase":"manga","readerBase":"chapter/{titleSlug}","searchBase":"search?q=","defaultLang":"en","titleIdType":"slug"},"releases":{"title":{"sel":".list-group-item .media","name":"h4.media-heading a|text","img":".media-left img|attr-contain:src","url":".media-heading a|attr:href","at":".media-heading .small|text","chapter":{"sel":".media-body > a","label":"|text","url":"|attr:href"}}},"title":{"sel":"#chapters-tab .tab-content","name":"#mangadetail h1|text","img":"#mangadetail img.manga-thumb|attr-contain:src","tags":"#mangadetail a.genre-label|text","chapter":{"sel":"#chapters-tab li.list-group-item","label":"a > span:first-child > span:first-child|text","url":"a|attr:href","at":"small|text"}},"reader":{"sel":"#mangareader","label":"h3|text","img":"#mangareader div img[alt]|attr-contain:src","prev":".chapter-pager .previous a[href*=\"/chapter/\"]|attr:href","next":".chapter-pager .next a[href*=\"/chapter/\"]|attr:href","title":{"sel":"h3 a","name":"|text","url":"|attr:href"},"chapter":{"sel":".pager-dropdown .dropdown-menu > li > a","label":"|text","url":"|attr:href"}},"search":{"title":{"sel":".media-manga","name":"h4 a|text","img":".media-left img|attr-contain:src","url":"h4 a|attr:href","chapter":{"sel":".media-body","label":"a[href*=\"/chapter/\"]|text","url":"a[href*=\"/chapter/\"]|attr:href"}}}},{"404":"#content > .wrapper > .notf img","id":"manhwafreak","meta":{"releases":"","titleBase":"manga","readerBase":"","searchBase":"?s=","idBase":"?p=","defaultLang":"en","titleIdType":"name"},"releases":{"title":{"sel":".lastest .lastest-serie","name":".lastest-title a|text","img":".img img|attr-contain:src","url":"a|attr:href","chapter":{"sel":".lastest-chap > a","label":"li|text","url":"|attr:href","at":"li span|text"}}},"title":{"sel":".series + .chapters .chapter-li","name":".series h1.title|text","img":".series .info img|attr-contain:src","tags":"#info > .left > div > p:first-child|row:genre(s)","type":"#info > .left > div > p:first-child|row:type","chapter":{"sel":".chapter-li > a","label":".chapter-info p|text","url":"|attr:href","at":".chapter-info p:nth-child(2)|text"}},"reader":{"sel":"#readerarea","label":"h2.entry-title|text","img":"#readerarea img.ts-main-image[data-index]|[attr:data-src,attr-contain:src]","prev":"a.ch-prev-btn:not(.disabled)|attr:href","next":"a.ch-next-btn:not(.disabled)|attr:href","title":{"sel":".breadcrumb > ul > li:nth-child(3) a","name":"span|text","url":"|attr:href"},"chapter":{"sel":".ctop select#chapter option:not([disabled]):not([value=\"\"])","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":".listupd .lastest-serie","name":".lastest-title|text","url":"a|attr:href","img":"img.ts-post-image|attr-contain:src","chapter":{"sel":".lastest-chap > a","label":"li|text","url":"|attr:href","at":"li span|text"}}}},{"404":".error-404.not-found","id":"nettruyen","meta":{"releases":"","titleBase":"truyen-tranh","readerBase":"truyen-tranh/{titleSlug}","searchBase":"tim-truyen?keyword=","defaultLang":"vi","titleIdType":"id"},"releases":{"title":{"sel":".items > .row > .item","id":".comic-item|attr:data-id","name":"h3 a|text","img":".image img|attr-contain:src","url":"h3 a|attr:href","chapter":{"sel":".chapter","label":"a|text","url":"a|attr:href","at":".time|text"}}},"title":{"id":".rating .star[data-id],.follow-link[data-id]|attr:data-id","name":"#item-detail h1.title-detail|text","img":"#item-detail .detail-info img|attr-contain:src","tags":".kind a[href*=\"/tim-truyen/\"]|text","chapter":{"sel":"#nt_listchapter nav > ul > li.row","label":".chapter a|text","url":".chapter a|attr:href","at":".small|text"}},"reader":{"label":"a.itemcrumb.active > span[itemprop=\"name\"]|text","img":".reading-detail > .page-chapter > img,.reading-detail > img|[attr:data-original,attr-contain:src]","prev":"a.prev.a_prev:not(.disabled)|attr:href","next":"a.next.a_next:not(.disabled)|attr:href","title":{"sel":"h1.txt-primary a","id":".follow-link[data-id]|attr:data-id","name":"|text","url":"|attr:href"}},"search":{"title":{"sel":".items > .row > .item","name":"h3 a|text","img":".image img|attr-contain:src","url":"h3 a|attr:href"}}},{"id":"manga4life","meta":{"releases":"","titleBase":"manga","readerBase":"read-online","searchBase":"search/?name=","defaultLang":"en","titleIdType":"slug"},"releases":{"title":{"sel":".BoxBody.LatestChapters .Chapter","name":".Image > a|attr:title","img":".Image > a img|attr-contain:src","url":".Image > a|attr:href","chapter":{"sel":".Label > a","label":".ChapterLabel|text","url":"|attr:href","at":".DateLabel|text"}}},"title":{"name":".BoxBody h1|text","img":"meta[property=\"og:image\"],meta[property=\"twitter:image:src\"]|attr:content","tags":"a[href*=\"search/?genre=\"]|text","type":"a[href*=\"search/?type=\"]|text"},"reader":{"label":"button[data-target=\"#ChapterModal\"]|text","img":".ImageGallery img.img-fluid|attr:ng-src","title":{"sel":".DesktopNav a","name":"|text","url":"|attr:href"}},"search":{"title":{"sel":".SearchFilterNav + .row > div[ng-repeat^=\"Series\"]","name":"div:nth-child(2) a.SeriesName|text","img":"img|attr-contain:src","url":"a|attr:href"}}},{"id":"mangadex","meta":{"releases":"about:blank","titleBase":"title","readerBase":"chapter","searchBase":"titles?q=","defaultLang":"en","chapters":"about:blank","titleIdType":"slug"}},{"id":"comick","meta":{"home":"home","releases":"about:blank","titleBase":"comic","readerBase":"comic/{titleSlug}","searchBase":"search?q=","defaultLang":"en","chapters":"about:blank","titleIdType":"id"},"releases":{"title":{"sel":"#updates-container div[title]","name":"|attr:title","img":"img|attr-contain:src","url":"a[href^=\"/comic/\"]|attr:href","chapter":{"sel":"a:last-child","label":"div:first-child|text","url":"|attr:href","at":"div:nth-child(2)|text"}}},"title":{"name":"h1|text","img":"a[href$=\"/covers\"] > img|attr-contain:src","langs":"#chapter-header + div select option:not([value=\"\"]):not([value=\"all\"])|attr:value","tags":"table a.link[href^=\"/search?genres=\"]|text","type":"h1 ~ div.text-sm span:first-child|row:origination"},"reader":{"lazy":true,"sel":".reader-container","label":"select:first-of-type option[selected]|text","img":".reader-container img|attr-contain:src","title":{"sel":"div > a[href*=\"/comic/\"]","name":"|text || img[alt]|attr:alt","url":"|attr:href","img":"img|attr-contain:src"},"lang":"select:nth-child(2)|value","prev":".reader-container a:first-child[href^=\"/comic/\"]:not(:last-child)|attr:href","next":".reader-container a:last-child[href^=\"/comic/\"]|attr:href","chapter":{"sel":"select:first-of-type option:not([disabled]):not([value=\"\"])","label":"|text","url":"|attr:value"}}},{"id":"bato","meta":{"releases":"","titleBase":"series","readerBase":"chapter","searchBase":"search?word=","defaultLang":"en","titleIdType":"slug"},"releases":{"title":{"sel":"#series-list > .item","name":"a.item-title|text","img":".item-cover img|attr-contain:src","url":"a.item-title|attr:href","lang":"em[data-lang]|attr:data-lang","chapter":{"sel":".item-volch","label":"a|text","url":"a|attr:href","at":"i|text"}}},"title":{"name":"h3.item-title a|text","img":".attr-cover > img|attr-contain:src","langs":".title-set em[data-lang]|attr:data-lang","tags":".attr-main .attr-item .text-muted|row:genres","chapter":{"sel":".episode-list > .main > .item","label":"a.chapt > b|text","url":"a.chapt|attr:href","at":".extra > i|text"}},"reader":{"label":"title|text","img":"img.page-img|attr-contain:src","title":{"sel":"h3.nav-title a","name":"|text","url":"|attr:href"},"lang":"h3.nav-title em[data-lang]|attr:data-lang","prev":".nav-prev > a[href^=\"/chapter/\"]|attr:href","next":".nav-next > a[href^=\"/chapter/\"]|attr:href","chapter":{"sel":".nav-epis > select option:not([disabled]):not([value=\"\"])","label":"|text","url":"|attr:value"}}},{"404":"#error > .attention","id":"mangago","meta":{"releases":"list/latest","titleBase":"read-manga","readerBase":"read-manga/{titleSlug}","searchBase":"r/l_search/?name=","defaultLang":"en","titleIdType":"slug"},"releases":{"title":{"sel":"#search_list > li .box","name":"a.thm-effect|attr:title","img":"a.thm-effect img|attr-contain:src","url":"a.thm-effect|attr:href","chapter":{"sel":"a.chico","label":"|text","url":"|attr:href"}}},"title":{"name":".w-title h1|text","img":".article .cover img|attr-contain:src","tags":".manga_right a[href*=\"/genre/\"]|text","chapter":{"sel":"#chapter_table tbody tr","label":"h4 a b|text","url":"h4 a|attr:href","at":"td:last-child|text"}},"reader":{"label":"#navi h3 span:last-child|text","img":"#pic_container img[id^=\"page\"]|attr-contain:src","title":{"sel":"#navi a#series","name":"|text","url":"|attr:href"},"chapter":{"sel":"ul.dropdown-menu.chapter > li > a","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":"#search_list > li .box","name":"a.thm-effect|attr:title","img":"a.thm-effect img|attr-contain:src","url":"a.thm-effect|attr:href","chapter":{"sel":"a.chico","label":"|text","url":"|attr:href"}}}},{"404":".nf-large + .nf-desc + a[href=\"/home\"]","id":"kakalot","meta":{"home":"home","releases":"home","titleBase":"","readerBase":"read/{titleSlug}/{lang}","searchBase":"search?keyword=","defaultLang":"en","titleIdType":"id"},"releases":{"title":{"sel":"#latest-chap .inner > .item","id":".item-info h3|attr:data-id","name":".item-info h3 a|text","img":".item-poster img|attr-contain:src","url":"a|attr:href","chapter":{"sel":".chapter-list > .cl-item","label":"a.chapter-name|text","url":"a|attr:href","at":".time|text"}}},"title":{"lazy":true,"sel":"#chapt-list .cl-header","id":"#main|attr:data-id","name":".detail-box h3.manga-name|text","img":".detail-box .manga-poster-img|attr-contain:src","tags":".detail-box .line-content a[href*=\"/genre/\"]|text","langs":"#chap-lang .lang-item|attr:data-code","chapter":{"sel":"#chapt-list .reading-list > .item","label":"a.chapter-name|text","url":"a.chapter-name|attr:href","at":".item-time|text"}},"reader":{"label":".breadcrumb-item.active|text","img":"#list-image .card-wrap[data-url]|attr:data-url","title":{"sel":".breadcrumb-item:nth-child(2) a","id":"#reading|attr:data-manga-id","name":"|text","url":"|attr:href"},"chapter":{"sel":".kbreadcrumb + .reading-option option.reading-item","label":"|text","url":"|attr:value"}},"search":{"title":{"sel":".manga-list > .inner > .item","name":".manga-name a|attr:title","img":".manga-poster img|attr-contain:src","url":".manga-name a|attr:href","chapter":{"sel":".latest-chapter .chapter-name","label":"|text","url":"|attr:href"}}}},{"id":"reaper","meta":{"releases":"latest/comics","titleBase":"comics","readerBase":"comics/{titleSlug}/chapters","searchBase":"?s=","defaultLang":"en","titleIdType":"name"},"releases":{"title":{"sel":"main h2 + div .grid.grid-cols-1 > div","img":"a img|attr-contain:src","name":"p a|text","url":"a|attr:href","chapter":{"sel":"p + div > a","label":"|text","url":"|attr:href","at":"p|text"}}},"title":{"sel":"div > ul[role=\"list\"]:first-child","name":"h1|text","img":"main .container img[alt]|attr-contain:src","chapter":{"sel":"div > ul[role=\"list\"]:first-child li[wire\\:key^=\"comic-chapter-list\"] a","label":"p|text","url":"|attr:href","at":"div:last-child > p|text"}},"reader":{"label":"title|text","img":"main nav ~ img.max-w-full|attr-contain:src","prev":"main nav:first-of-type > div:first-child a|attr:href","next":"main nav:first-of-type > div:last-child a:last-child:not(:first-child)|attr:href","title":{"sel":"body","name":"main p|text","url":"main nav:first-of-type > div:last-child a:first-child|attr:href"}}},{"id":"tapas","meta":{"titleBase":"series/{slug}/info","readerBase":"episode","defaultLang":"en","titleIdType":"id","chapters":"about:blank"},"title":{"id":".button--subscribe|attr:data-tiara-event-meta-series-id","name":".info .title|text","img":".thumb img|attr:src","chapter":{"sel":".episode-list .episode-list__item > a","url":"|attr:data-id","label":"|attr:data-scene-number"}},"reader":{"id":"div[id^=\"episode-\"][data-ep-id]|attr:data-ep-id","label":"div[id^=\"episode-\"][data-ep-scene]|attr:data-ep-scene","img":".viewer__body img|[attr:data-src,attr-contain:src]","prev":"div[data-prev-id]:not([data-prev-id=\"-1\"])|attr:data-prev-id","next":"div[data-next-id]:not([data-next-id=\"-1\"])|attr:data-next-id","title":{"sel":"body","id":".subscribe-btn|attr:data-id","url":".subscribe-btn|attr:data-id","name":".series-info .title|text","img":".series-info .thumb img|attr:src"},"chapter":{"sel":".episode-list .list-body > li[data-id]","url":"|attr:data-id","label":".info__label|text"}}}]
|
package/tags.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"id":1,"category":0,"name":"Manga"},{"id":2,"category":0,"name":"Manhua"},{"id":3,"category":0,"name":"Manhwa"},{"id":4,"category":0,"name":"Comic"},{"id":5,"category":0,"name":"Novel"},{"id":6,"category":0,"name":"Anime"},{"id":7,"category":0,"name":"Donghua"},{"id":11,"category":1,"name":"Shounen"},{"id":12,"category":1,"name":"Shoujo"},{"id":13,"category":1,"name":"Seinen"},{"id":14,"category":1,"name":"Josei"},{"id":15,"category":1,"name":"Yaoi"},{"id":16,"category":1,"name":"Yuri"},{"id":20,"category":2,"name":"4 Koma"},{"id":21,"category":2,"name":"Adaptation"},{"id":22,"category":2,"name":"Anthology"},{"id":23,"category":2,"name":"Award Winning"},{"id":24,"category":2,"name":"Doujinshi"},{"id":25,"category":2,"name":"Fan Colored"},{"id":26,"category":2,"name":"Full Color"},{"id":27,"category":2,"name":"Long Strip"},{"id":28,"category":2,"name":"Official Colored"},{"id":29,"category":2,"name":"Oneshot"},{"id":20,"category":2,"name":"Self Published"},{"id":31,"category":2,"name":"Web Comic"},{"id":40,"category":3,"name":"Adult"},{"id":41,"category":3,"name":"Bloody"},{"id":42,"category":3,"name":"Ecchi"},{"id":43,"category":3,"name":"Erotica"},{"id":44,"category":3,"name":"Gore"},{"id":45,"category":3,"name":"Hentai"},{"id":46,"category":3,"name":"Mature"},{"id":47,"category":3,"name":"Smut"},{"id":
|
|
1
|
+
[{"id":1,"category":0,"name":"Manga"},{"id":2,"category":0,"name":"Manhua"},{"id":3,"category":0,"name":"Manhwa"},{"id":4,"category":0,"name":"Comic"},{"id":5,"category":0,"name":"Novel"},{"id":6,"category":0,"name":"Anime"},{"id":7,"category":0,"name":"Donghua"},{"id":11,"category":1,"name":"Shounen"},{"id":12,"category":1,"name":"Shoujo"},{"id":13,"category":1,"name":"Seinen"},{"id":14,"category":1,"name":"Josei"},{"id":15,"category":1,"name":"Yaoi","altNames":["shounen ai"]},{"id":16,"category":1,"name":"Yuri","altNames":["shoujo ai"]},{"id":20,"category":2,"name":"4 Koma"},{"id":21,"category":2,"name":"Adaptation"},{"id":22,"category":2,"name":"Anthology"},{"id":23,"category":2,"name":"Award Winning"},{"id":24,"category":2,"name":"Doujinshi"},{"id":25,"category":2,"name":"Fan Colored"},{"id":26,"category":2,"name":"Full Color"},{"id":27,"category":2,"name":"Long Strip"},{"id":28,"category":2,"name":"Official Colored"},{"id":29,"category":2,"name":"Oneshot"},{"id":20,"category":2,"name":"Self Published"},{"id":31,"category":2,"name":"Web Comic"},{"id":40,"category":3,"name":"Adult"},{"id":41,"category":3,"name":"Bloody"},{"id":42,"category":3,"name":"Ecchi"},{"id":43,"category":3,"name":"Erotica"},{"id":44,"category":3,"name":"Gore"},{"id":45,"category":3,"name":"Hentai"},{"id":46,"category":3,"name":"Mature"},{"id":47,"category":3,"name":"Smut"},{"id":49,"category":3,"name":"Violence"},{"id":60,"name":"Action"},{"id":61,"name":"Adventure"},{"id":62,"name":"Age Gap"},{"id":63,"name":"Aliens"},{"id":64,"name":"Animals"},{"id":65,"name":"Beasts"},{"id":66,"name":"Bodyswap"},{"id":67,"name":"Boys' Love","altNames":["shounen ai"]},{"id":68,"name":"Cheating","altNames":["infideli"]},{"id":69,"name":"Childhood Friends"},{"id":70,"name":"Comedy","altNames":["funny"]},{"id":71,"name":"Cooking"},{"id":72,"name":"Crime"},{"id":73,"name":"Cross Dressing"},{"id":74,"name":"Crossdressing"},{"id":75,"name":"Cultivation"},{"id":76,"name":"Delinquents"},{"id":77,"name":"Demons"},{"id":78,"name":"Detective"},{"id":79,"name":"Drama"},{"id":80,"name":"Dungeons"},{"id":81,"name":"Fantasy"},{"id":82,"name":"Fetish"},{"id":83,"name":"Food"},{"id":84,"name":"Game"},{"id":85,"name":"Genderswap"},{"id":86,"name":"Ghosts"},{"id":87,"name":"Girls' Love"},{"id":88,"name":"Gyaru"},{"id":89,"name":"Harem"},{"id":90,"name":"Historical"},{"id":91,"name":"Horror"},{"id":92,"name":"Incest"},{"id":93,"name":"Isekai"},{"id":94,"name":"Loli","altNames":["lolicon"]},{"id":95,"name":"Mafia"},{"id":96,"name":"Magic"},{"id":97,"name":"Magical Girls","altNames":["mahou shoujo"]},{"id":98,"name":"Martial Arts","altNames":["martial"]},{"id":99,"name":"Mecha"},{"id":100,"name":"Medical"},{"id":101,"name":"Military"},{"id":102,"name":"Modern Setting"},{"id":103,"name":"Monster Girls"},{"id":104,"name":"Monsters"},{"id":105,"name":"Murim"},{"id":106,"name":"Music"},{"id":107,"name":"Mystery"},{"id":108,"name":"Ninja"},{"id":109,"name":"Office Workers"},{"id":110,"name":"Overpowered"},{"id":111,"name":"Parody"},{"id":112,"name":"Philosophical"},{"id":113,"name":"Police"},{"id":114,"name":"Post Apocalyptic","altNames":["apocalypse"]},{"id":115,"name":"Psychological"},{"id":116,"name":"Reincarnation","altNames":["regression","rebirth","reincarnate","return","returned","returner"]},{"id":117,"name":"Revenge"},{"id":118,"name":"Reverse Harem"},{"id":119,"name":"Romance"},{"id":120,"name":"Royalty"},{"id":121,"name":"Samurai"},{"id":122,"name":"School Life"},{"id":123,"name":"Sci Fi"},{"id":124,"name":"Science Fiction"},{"id":125,"name":"Shota"},{"id":126,"name":"Slice of Life"},{"id":127,"name":"Sports"},{"id":128,"name":"Superhero"},{"id":129,"name":"Supernatural"},{"id":130,"name":"Survival"},{"id":131,"name":"System","altNames":["cheat system"]},{"id":132,"name":"Thriller"},{"id":133,"name":"Time Travel"},{"id":134,"name":"Traditional Games"},{"id":135,"name":"Tragedy"},{"id":136,"name":"Transmigration"},{"id":137,"name":"Vampires"},{"id":138,"name":"Video Games"},{"id":139,"name":"Villain"},{"id":140,"name":"Villainess"},{"id":141,"name":"Virtual Reality"},{"id":142,"name":"Webtoon"},{"id":143,"name":"Wuxia"},{"id":144,"name":"Yakuzas"},{"id":145,"name":"Zombies"}]
|