mirror of
https://git.mihon.tech/mihonapp/mihon
synced 2024-11-23 05:35:51 +03:00
Extra genre chip text trimming
This commit is contained in:
parent
8de004d281
commit
088160ed32
1 changed files with 9 additions and 7 deletions
|
@ -245,14 +245,16 @@ class MangaInfoController : NucleusController<MangaInfoPresenter>(),
|
|||
if (!manga.genre.isNullOrBlank()) {
|
||||
binding.mangaGenresTags.removeAllViews()
|
||||
|
||||
manga.genre?.split(", ")?.forEach { genre ->
|
||||
val chip = Chip(view.context).apply {
|
||||
text = genre
|
||||
setOnClickListener { performSearch(genre) }
|
||||
}
|
||||
manga.genre?.split(", ").orEmpty()
|
||||
.map { it.trim() }
|
||||
.forEach { genre ->
|
||||
val chip = Chip(view.context).apply {
|
||||
text = genre
|
||||
setOnClickListener { performSearch(genre) }
|
||||
}
|
||||
|
||||
binding.mangaGenresTags.addView(chip)
|
||||
}
|
||||
binding.mangaGenresTags.addView(chip)
|
||||
}
|
||||
}
|
||||
|
||||
// Update description TextView.
|
||||
|
|
Loading…
Reference in a new issue