Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -800,6 +800,9 @@ private fun BadgePill(label: String) {
fontWeight = FontWeight.Bold,
letterSpacing = 0.8.sp, // iOS tracking 0.8
maxLines = 1,
// Wrapping drew only the first word in a full-width pill.
softWrap = false,
overflow = TextOverflow.Ellipsis,
color = MaterialTheme.colorScheme.background,
)
}
Expand Down Expand Up @@ -863,8 +866,10 @@ private fun EmptyState(filter: String, onShowEverything: () -> Unit) {
}

private fun badgeLabel(badge: String): String? = when (badge) {
// iOS CalendarBadge labels (uppercased editorial).
CalendarBadge.SeriesPremiere -> "SERIES PREMIERE"
// iOS CalendarBadge labels (uppercased editorial). iOS says "SERIES
// PREMIERE", which does not fit a poster at the 11sp badge floor;
// NEW SEASON already marks season premieres.
CalendarBadge.SeriesPremiere -> "PREMIERE"
CalendarBadge.SeasonPremiere -> "NEW SEASON"
CalendarBadge.Finale -> "FINALE"
else -> null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1561,6 +1561,9 @@ private fun BadgePill(text: String) {
fontWeight = FontWeight.Bold,
color = Color.Black,
maxLines = 1,
// Wrapping drew only the first word in a full-width pill.
softWrap = false,
overflow = TextOverflow.Ellipsis,
)
}
}
Expand Down Expand Up @@ -1650,7 +1653,9 @@ private fun CalendarMessage(
// MARK: - Formatting helpers

private fun badgeLabel(badge: String): String? = when (badge) {
CalendarBadge.SeriesPremiere -> "SERIES PREMIERE"
// tvOS says "SERIES PREMIERE", which does not fit a poster at 14sp;
// NEW SEASON already marks season premieres.
CalendarBadge.SeriesPremiere -> "PREMIERE"
CalendarBadge.SeasonPremiere -> "NEW SEASON"
CalendarBadge.Finale -> "FINALE"
else -> null
Expand Down
Loading