summaryrefslogtreecommitdiff
path: root/android/app
diff options
context:
space:
mode:
Diffstat (limited to 'android/app')
-rw-r--r--android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt18
1 files changed, 16 insertions, 2 deletions
diff --git a/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt b/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt
index a7b09b4..49b277a 100644
--- a/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt
+++ b/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt
@@ -223,6 +223,7 @@ fun WidgetRoot(items: List<WidgetItem>, now: Instant, isRefreshing: Boolean, tex
@Composable
fun AllDayRow(event: WidgetItem, textSize: WidgetTextSize, variant: MultiDayVariant = MultiDayVariant.NONE) {
val color = sourceColor(event.source)
+ val label = multiDayLabel(event, variant)
Row(
modifier = GlanceModifier
.fillMaxWidth()
@@ -232,15 +233,28 @@ fun AllDayRow(event: WidgetItem, textSize: WidgetTextSize, variant: MultiDayVari
) {
Box(modifier = GlanceModifier.width(3.dp).height(16.dp).background(color)) {}
Text(
- text = event.title + multiDayLabel(event, variant),
+ text = event.title,
style = TextStyle(
color = ColorProvider(Color.White.copy(alpha = 0.9f)),
fontSize = textSize.scaledContentSize(13),
fontWeight = textSize.scaledContentWeight(FontWeight.Medium)
),
- modifier = GlanceModifier.padding(start = 8.dp),
+ modifier = GlanceModifier.padding(start = 8.dp).defaultWeight(),
maxLines = 1
)
+ if (label.isNotEmpty()) {
+ Text(
+ // Full opacity, matching EventBlock's upcoming (non-past) events --
+ // the label is time-relevant info, not secondary chrome.
+ text = label,
+ style = TextStyle(
+ color = ColorProvider(Color.White.copy(alpha = 1f)),
+ fontSize = textSize.scaledContentSize(13),
+ fontWeight = textSize.scaledContentWeight(FontWeight.Medium)
+ ),
+ maxLines = 1
+ )
+ }
}
}