11package com.readrops.app.item.components
22
3+ import androidx.compose.foundation.layout.Arrangement
34import androidx.compose.foundation.layout.Column
5+ import androidx.compose.foundation.layout.FlowRow
46import androidx.compose.foundation.layout.fillMaxWidth
57import androidx.compose.foundation.layout.padding
68import androidx.compose.foundation.shape.CircleShape
@@ -22,6 +24,7 @@ import com.readrops.app.util.DefaultPreview
2224import com.readrops.app.util.components.FeedIcon
2325import com.readrops.app.util.components.IconText
2426import com.readrops.app.util.extensions.displayColor
27+ import com.readrops.app.util.theme.MediumSpacer
2528import com.readrops.app.util.theme.ReadropsTheme
2629import com.readrops.app.util.theme.ShortSpacer
2730import com.readrops.app.util.theme.spacing
@@ -38,6 +41,7 @@ fun SimpleTitle(
3841) {
3942 val item = itemWithFeed.item
4043 val spacing = MaterialTheme .spacing.mediumSpacing
44+ val accentColor = itemWithFeed.displayColor(MaterialTheme .colorScheme.background.toArgb())
4145
4246 Column (
4347 horizontalAlignment = Alignment .CenterHorizontally ,
@@ -100,6 +104,26 @@ fun SimpleTitle(
100104 style = MaterialTheme .typography.labelMedium,
101105 color = onBackgroundColor
102106 )
107+
108+ if (itemWithFeed.item.tags.isNotEmpty()) {
109+ MediumSpacer ()
110+
111+ FlowRow (
112+ horizontalArrangement = Arrangement .spacedBy(
113+ MaterialTheme .spacing.shortSpacing,
114+ Alignment .CenterHorizontally
115+ ),
116+ verticalArrangement = Arrangement .spacedBy(MaterialTheme .spacing.shortSpacing)
117+ ) {
118+ for (tag in itemWithFeed.item.tags) {
119+ TagSurface (
120+ name = tag.name,
121+ backgroundColor = accentColor
122+ )
123+
124+ }
125+ }
126+ }
103127 }
104128}
105129
0 commit comments