From bd7b21337ca9bee98877cae298784401a4a4e7b7 Mon Sep 17 00:00:00 2001 From: Ivan Iskandar <12537387+ivaniskandar@users.noreply.github.com> Date: Tue, 21 Feb 2023 23:44:56 +0700 Subject: [PATCH] Add minLines to comfortable grid item title (#9122) --- .../kanade/presentation/library/components/CommonMangaItem.kt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/src/main/java/eu/kanade/presentation/library/components/CommonMangaItem.kt b/app/src/main/java/eu/kanade/presentation/library/components/CommonMangaItem.kt index 7e8617df5d..975d5e1b24 100644 --- a/app/src/main/java/eu/kanade/presentation/library/components/CommonMangaItem.kt +++ b/app/src/main/java/eu/kanade/presentation/library/components/CommonMangaItem.kt @@ -144,6 +144,7 @@ private fun BoxScope.CoverTextOverlay( blurRadius = 4f, ), ), + minLines = 1, ) if (onClickContinueReading != null) { ContinueReadingButton( @@ -204,6 +205,7 @@ fun MangaComfortableGridItem( modifier = Modifier.padding(4.dp), title = title, style = MaterialTheme.typography.titleSmall, + minLines = 2, ) } } @@ -252,12 +254,14 @@ private fun GridItemTitle( modifier: Modifier, title: String, style: TextStyle, + minLines: Int, ) { Text( modifier = modifier, text = title, fontSize = 12.sp, lineHeight = 18.sp, + minLines = minLines, maxLines = 2, overflow = TextOverflow.Ellipsis, style = style,