Add Hentaing (#3885)
* Add Hentaing * remove page if imageUrl is null also
This commit is contained in:
parent
102b91f959
commit
8dc7c90005
|
@ -0,0 +1,10 @@
|
||||||
|
ext {
|
||||||
|
extName = 'Hentaing'
|
||||||
|
extClass = '.Hentaing'
|
||||||
|
themePkg = 'madara'
|
||||||
|
baseUrl = 'https://hentaing.org'
|
||||||
|
overrideVersionCode = 0
|
||||||
|
isNsfw = true
|
||||||
|
}
|
||||||
|
|
||||||
|
apply from: "$rootDir/common.gradle"
|
Binary file not shown.
After Width: | Height: | Size: 6.7 KiB |
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
Binary file not shown.
After Width: | Height: | Size: 11 KiB |
Binary file not shown.
After Width: | Height: | Size: 23 KiB |
Binary file not shown.
After Width: | Height: | Size: 38 KiB |
|
@ -0,0 +1,32 @@
|
||||||
|
package eu.kanade.tachiyomi.extension.tr.hentaing
|
||||||
|
|
||||||
|
import eu.kanade.tachiyomi.multisrc.madara.Madara
|
||||||
|
import eu.kanade.tachiyomi.source.model.Page
|
||||||
|
import org.jsoup.nodes.Document
|
||||||
|
import java.text.SimpleDateFormat
|
||||||
|
import java.util.Locale
|
||||||
|
|
||||||
|
class Hentaing : Madara(
|
||||||
|
"Hentaing",
|
||||||
|
"https://hentaing.org",
|
||||||
|
"tr",
|
||||||
|
dateFormat = SimpleDateFormat("MMMM d, yyyy", Locale("tr")),
|
||||||
|
) {
|
||||||
|
override val useLoadMoreRequest = LoadMoreStrategy.Always
|
||||||
|
override val useNewChapterEndpoint = true
|
||||||
|
|
||||||
|
override fun pageListParse(document: Document): List<Page> {
|
||||||
|
val pageList = super.pageListParse(document)
|
||||||
|
|
||||||
|
if (
|
||||||
|
pageList.isEmpty() &&
|
||||||
|
document.select(".content-blocked, .login-required").isNotEmpty()
|
||||||
|
) {
|
||||||
|
throw Exception("Okumak için WebView üzerinden giriş yapın")
|
||||||
|
}
|
||||||
|
|
||||||
|
return pageList.filterNot { it.imageUrl?.let(patternBadImage::containsMatchIn) ?: true }
|
||||||
|
}
|
||||||
|
|
||||||
|
private val patternBadImage = """/\.(?:webp|jpeg|tiff|.{3})$""".toRegex()
|
||||||
|
}
|
Loading…
Reference in New Issue