FoolSlide: Update Hentai Cafe filters (#1539)

Signed-off-by: Rama Bondan Prakoso <ramanarubp@gmail.com>
This commit is contained in:
Rama Bondan Prakoso 2019-09-21 09:10:03 +07:00 committed by arkon
parent a096994319
commit 05578e60e9
2 changed files with 5 additions and 4 deletions

View File

@ -5,7 +5,7 @@ ext {
appName = 'Tachiyomi: FoolSlide' appName = 'Tachiyomi: FoolSlide'
pkgNameSuffix = 'all.foolslide' pkgNameSuffix = 'all.foolslide'
extClass = '.FoolSlideFactory' extClass = '.FoolSlideFactory'
extVersionCode = 25 extVersionCode = 26
libVersion = '1.2' libVersion = '1.2'
} }

View File

@ -73,7 +73,7 @@ class HentaiCafe : FoolSlide("Hentai Cafe", "https://hentai.cafe", "en", "/manga
filters.findInstance<ArtistFilter>()?.let { f -> filters.findInstance<ArtistFilter>()?.let { f ->
if (f.state.isNotBlank()) { if (f.state.isNotBlank()) {
requireNoUrl() requireNoUrl()
url = "/artist/${f.state url = "/hc.fyi/artist/${f.state
.trim() .trim()
.toLowerCase() .toLowerCase()
.replace(ARTIST_INVALID_CHAR_REGEX, "-")}/" .replace(ARTIST_INVALID_CHAR_REGEX, "-")}/"
@ -82,13 +82,13 @@ class HentaiCafe : FoolSlide("Hentai Cafe", "https://hentai.cafe", "en", "/manga
filters.findInstance<BookFilter>()?.let { f -> filters.findInstance<BookFilter>()?.let { f ->
if (f.state) { if (f.state) {
requireNoUrl() requireNoUrl()
url = "/category/book/" url = "/hc.fyi/category/book/"
} }
} }
filters.findInstance<TagFilter>()?.let { f -> filters.findInstance<TagFilter>()?.let { f ->
if (f.state != 0) { if (f.state != 0) {
requireNoUrl() requireNoUrl()
url = "/tag/${f.values[f.state].name}/" url = "/hc.fyi/tag/${f.values[f.state].name}/"
} }
} }
@ -140,6 +140,7 @@ class HentaiCafe : FoolSlide("Hentai Cafe", "https://hentai.cafe", "en", "/manga
class ArtistFilter : Filter.Text("Artist (must be exact match)") class ArtistFilter : Filter.Text("Artist (must be exact match)")
class BookFilter : Filter.CheckBox("Show books only", false) class BookFilter : Filter.CheckBox("Show books only", false)
class TagFilter : Filter.Select<Tag>("Tag", arrayOf( class TagFilter : Filter.Select<Tag>("Tag", arrayOf(
Tag("", "<select>"),
Tag("ahegao", "Ahegao"), Tag("ahegao", "Ahegao"),
Tag("anal", "Anal"), Tag("anal", "Anal"),
Tag("big-ass", "Big ass"), Tag("big-ass", "Big ass"),