[RU]MangaClub fix chapters load (#18286)
This commit is contained in:
parent
e9bf94f4e5
commit
15c3d65f7c
|
@ -5,7 +5,7 @@ ext {
|
||||||
extName = 'MangaClub'
|
extName = 'MangaClub'
|
||||||
pkgNameSuffix = 'ru.mangaclub'
|
pkgNameSuffix = 'ru.mangaclub'
|
||||||
extClass = '.MangaClub'
|
extClass = '.MangaClub'
|
||||||
extVersionCode = 11
|
extVersionCode = 12
|
||||||
}
|
}
|
||||||
|
|
||||||
apply from: "$rootDir/common.gradle"
|
apply from: "$rootDir/common.gradle"
|
||||||
|
|
|
@ -93,18 +93,18 @@ class MangaClub : ParsedHttpSource() {
|
||||||
|
|
||||||
/** Details **/
|
/** Details **/
|
||||||
override fun mangaDetailsParse(document: Document): SManga = SManga.create().apply {
|
override fun mangaDetailsParse(document: Document): SManga = SManga.create().apply {
|
||||||
val licensedStatus = document.select("div.fullstory").text().contains("Данное произведение лицензировано на территории РФ. Главы удалены.")
|
|
||||||
thumbnail_url = document.select("div.image img").attr("abs:src")
|
thumbnail_url = document.select("div.image img").attr("abs:src")
|
||||||
title = document.select("div.info strong").text().replace("\\'", "'").substringBefore("/").trim()
|
title = document.select("div.info strong").text().replace("\\'", "'").substringBefore("/").trim()
|
||||||
author = document.select("div.info a[href*=author]").joinToString(", ") { it.text().trim() }
|
author = document.select("div.info a[href*=author]").joinToString(", ") { it.text().trim() }
|
||||||
artist = author
|
artist = author
|
||||||
status = when (document.select("div.info a[href*=status_translation]").text().trim()) {
|
status = if (document.select("div.fullstory").text().contains("Данное произведение лицензировано на территории РФ. Главы удалены.")) SManga.LICENSED else when (document.select("div.info a[href*=status_translation]").text().trim()) {
|
||||||
"Продолжается" -> if (licensedStatus) SManga.LICENSED else SManga.ONGOING
|
"Продолжается" -> SManga.ONGOING
|
||||||
"Завершен" -> if (licensedStatus) SManga.LICENSED else SManga.COMPLETED
|
"Завершен" -> SManga.COMPLETED
|
||||||
"Заморожено/Заброшено" -> if (licensedStatus) SManga.LICENSED else SManga.ON_HIATUS
|
"Заморожено/Заброшено" -> SManga.ON_HIATUS
|
||||||
else -> SManga.UNKNOWN
|
else -> SManga.UNKNOWN
|
||||||
}
|
}
|
||||||
description = "Читайте описание через WebView"
|
|
||||||
|
description = document.select(".description").first()!!.text()
|
||||||
genre = document.select("div.info a[href*=tags]").joinToString(", ") {
|
genre = document.select("div.info a[href*=tags]").joinToString(", ") {
|
||||||
it.text().replaceFirstChar { it.uppercase() }.trim()
|
it.text().replaceFirstChar { it.uppercase() }.trim()
|
||||||
}
|
}
|
||||||
|
@ -123,8 +123,8 @@ class MangaClub : ParsedHttpSource() {
|
||||||
|
|
||||||
/** Pages **/
|
/** Pages **/
|
||||||
override fun pageListParse(document: Document): List<Page> = mutableListOf<Page>().apply {
|
override fun pageListParse(document: Document): List<Page> = mutableListOf<Page>().apply {
|
||||||
document.select("div.manga-lines-page a").forEach {
|
document.select(".manga-lines-page a").forEach {
|
||||||
add(Page(it.attr("data-p").toInt(), "", "${baseUrl.replace("//", "//img.")}/${it.attr("data-i")}"))
|
add(Page(it.attr("data-p").toInt(), "", it.attr("data-i")))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
override fun imageUrlParse(document: Document): String = ""
|
override fun imageUrlParse(document: Document): String = ""
|
||||||
|
|
Loading…
Reference in New Issue