Workaround aspect is NaN, Resolve #1116
This commit is contained in:
1 parent
a8e3f67371
commit
2a34d6eb8b
1 file changed
+2
-1
@@ -129,7 +129,8 @@ fun GalleryInfoGridItem(
|
||||
info: GalleryInfo,
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
val aspect = (info.thumbWidth.toFloat() / info.thumbHeight).coerceIn(0.33F, 1.5F)
|
||||
var aspect = (info.thumbWidth.toFloat() / info.thumbHeight).coerceIn(0.33F, 1.5F)
|
||||
if (aspect.isNaN()) aspect = 1F
|
||||
val color = EhUtils.getCategoryColor(info.category)
|
||||
val simpleLang = info.simpleLanguage
|
||||
ElevatedCard(
|
||||
|
||||
Reference in new issue
Block a user