Skip to content

Commit

Permalink
fix(ui): add paddings to article item & fix ripple
Browse files Browse the repository at this point in the history
  • Loading branch information
JunkFood02 committed Feb 9, 2024
1 parent a5846d2 commit c21e22d
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions app/src/main/java/me/ash/reader/ui/page/home/flow/ArticleItem.kt
Original file line number Diff line number Diff line change
Expand Up @@ -96,20 +96,19 @@ fun ArticleItem(
if (articleWithFeed.article.isStarred) {
Icon(
modifier = Modifier
.alpha(0.7f)
.size(14.dp)
.padding(end = 2.dp),
imageVector = Icons.Rounded.Star,
contentDescription = stringResource(R.string.starred),
tint = MaterialTheme.colorScheme.outline,
tint = MaterialTheme.colorScheme.outlineVariant,
)
}

// Date
Text(
modifier = Modifier.alpha(0.7f),
modifier = Modifier,
text = articleWithFeed.article.dateString ?: "",
color = MaterialTheme.colorScheme.outline,
color = MaterialTheme.colorScheme.outlineVariant,
style = MaterialTheme.typography.labelMedium,
)
}
Expand All @@ -118,7 +117,7 @@ fun ArticleItem(

// Bottom
Row(
modifier = Modifier.fillMaxWidth(),
modifier = Modifier.fillMaxWidth().padding(top = 4.dp),
) {
// Feed icon
if (articleListFeedIcon.value) {
Expand All @@ -143,7 +142,7 @@ fun ArticleItem(
// Description
if (articleListDesc.value && articleWithFeed.article.shortDescription.isNotBlank()) {
Text(
modifier = Modifier.alpha(0.7f),
modifier = Modifier.padding(top = 4.dp),
text = articleWithFeed.article.shortDescription,
color = MaterialTheme.colorScheme.onSurfaceVariant,
style = MaterialTheme.typography.bodySmall,
Expand Down

0 comments on commit c21e22d

Please sign in to comment.