Madara - add Hunter Fansub (#1826)
This commit is contained in:
parent
ae1c22773a
commit
21a2d6ac3c
@ -5,7 +5,7 @@ ext {
|
||||
appName = 'Tachiyomi: Madara (multiple sources)'
|
||||
pkgNameSuffix = "all.madara"
|
||||
extClass = '.MadaraFactory'
|
||||
extVersionCode = 31
|
||||
extVersionCode = 32
|
||||
libVersion = '1.2'
|
||||
}
|
||||
|
||||
|
@ -44,11 +44,13 @@ abstract class Madara(
|
||||
|
||||
override fun popularMangaSelector() = "div.page-item-detail"
|
||||
|
||||
open val popularMangaUrlSelector = "div.post-title a"
|
||||
|
||||
override fun popularMangaFromElement(element: Element): SManga {
|
||||
val manga = SManga.create()
|
||||
|
||||
with(element) {
|
||||
select("div.post-title a").first()?.let {
|
||||
select(popularMangaUrlSelector).first()?.let {
|
||||
manga.setUrlWithoutDomain(it.attr("href"))
|
||||
manga.title = it.ownText()
|
||||
}
|
||||
|
@ -58,7 +58,8 @@ class MadaraFactory : SourceFactory {
|
||||
ToonManga(),
|
||||
Hiperdex(),
|
||||
DoujinHentai(),
|
||||
Azora()
|
||||
Azora(),
|
||||
HunterFansub()
|
||||
)
|
||||
}
|
||||
|
||||
@ -366,7 +367,7 @@ class DoujinHentai : Madara("DoujinHentai", "https://doujinhentai.net", "es", Si
|
||||
}
|
||||
|
||||
class Azora : Madara("Azora", "https://www.azoramanga.com", "ar") {
|
||||
override fun popularMangaRequest(page: Int): Request = GET("$baseUrl/?m_orderby=views", headers)
|
||||
override fun popularMangaRequest(page: Int): Request = GET("$baseUrl/page/$page/?m_orderby=views", headers)
|
||||
override fun searchMangaNextPageSelector() = "nav.navigation-ajax"
|
||||
override fun chapterListSelector() = "li.wp-manga-chapter:not(:has(img))" // Filter fake chapters
|
||||
override fun chapterFromElement(element: Element): SChapter {
|
||||
@ -379,3 +380,9 @@ class Azora : Madara("Azora", "https://www.azoramanga.com", "ar") {
|
||||
return chapter
|
||||
}
|
||||
}
|
||||
|
||||
class HunterFansub : Madara("Hunter Fansub", "https://hunterfansub.com", "es") {
|
||||
override fun popularMangaRequest(page: Int): Request = GET("$baseUrl/biblioteca/page/$page?m_orderby=views", headers)
|
||||
override fun popularMangaNextPageSelector() = "div.nav-previous"
|
||||
override val popularMangaUrlSelector = "div.post-title a:last-child"
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user