WP Comics fix manhuaES paging issue (#5488)
popular, latest, and search only show few manga (only page 1)
This commit is contained in:
parent
19adc29d1d
commit
85186e62a4
|
@ -5,7 +5,7 @@ ext {
|
||||||
extName = 'WP-Comics'
|
extName = 'WP-Comics'
|
||||||
pkgNameSuffix = 'all.wpcomics'
|
pkgNameSuffix = 'all.wpcomics'
|
||||||
extClass = '.WPComicsFactory'
|
extClass = '.WPComicsFactory'
|
||||||
extVersionCode = 19
|
extVersionCode = 20
|
||||||
libVersion = '1.2'
|
libVersion = '1.2'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,16 @@ class WPComicsFactory : SourceFactory {
|
||||||
|
|
||||||
private class ManhuaES : WPComics("Manhua ES", "https://manhuaes.com", "en", SimpleDateFormat("HH:mm - dd/MM/yyyy Z", Locale.US), "+0700") {
|
private class ManhuaES : WPComics("Manhua ES", "https://manhuaes.com", "en", SimpleDateFormat("HH:mm - dd/MM/yyyy Z", Locale.US), "+0700") {
|
||||||
override val popularPath = "category-comics/manga"
|
override val popularPath = "category-comics/manga"
|
||||||
|
override fun popularMangaRequest(page: Int): Request {
|
||||||
|
return GET("$baseUrl/$popularPath" + if (page > 1) "/page/$page" else "", headers)
|
||||||
|
}
|
||||||
|
override fun latestUpdatesRequest(page: Int): Request {
|
||||||
|
return GET(baseUrl + if (page > 1) "/page/$page" else "", headers)
|
||||||
|
}
|
||||||
|
override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request {
|
||||||
|
return GET("$baseUrl/page/$page/?s=$query&post_type=comics")
|
||||||
|
}
|
||||||
|
override fun popularMangaNextPageSelector() = ".pagination li:last-child:not(.active)"
|
||||||
override fun popularMangaFromElement(element: Element): SManga {
|
override fun popularMangaFromElement(element: Element): SManga {
|
||||||
return SManga.create().apply {
|
return SManga.create().apply {
|
||||||
element.select("div.overlay a:has(h2)").let {
|
element.select("div.overlay a:has(h2)").let {
|
||||||
|
@ -41,7 +50,6 @@ private class ManhuaES : WPComics("Manhua ES", "https://manhuaes.com", "en", Sim
|
||||||
thumbnail_url = element.select("img").firstOrNull()?.attr("abs:src")
|
thumbnail_url = element.select("img").firstOrNull()?.attr("abs:src")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override val pageListSelector = "div.chapter-detail ul img, div.chapter-detail div:not(.container) > img, div.chapter-detail p > img"
|
override val pageListSelector = "div.chapter-detail ul img, div.chapter-detail div:not(.container) > img, div.chapter-detail p > img"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue