Arcade cards tall enough for their line (from 0.108.31)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -369,12 +369,12 @@ private fun GameCard(game: ArcadeGame, modifier: Modifier, focus: FocusRequester
|
||||
Row(modifier.then(if (focus != null) Modifier.focusRequester(focus) else Modifier).focusProperties { if (up != null) this.up = up }
|
||||
.onFocusChanged { focused = it.isFocused; if (it.isFocused) onFocus() }
|
||||
.background(if (focused) Navy else Panel, corner).border(if (focused) 3.dp else 1.dp, if (focused) Yellow else Blue, corner)
|
||||
.clickable(onClick = onPlay).padding(horizontal = 10.dp, vertical = 6.dp), verticalAlignment = Alignment.CenterVertically, horizontalArrangement = Arrangement.spacedBy(10.dp)) {
|
||||
.clickable(onClick = onPlay).padding(horizontal = 10.dp, vertical = 4.dp), verticalAlignment = Alignment.CenterVertically, horizontalArrangement = Arrangement.spacedBy(10.dp)) {
|
||||
Canvas(Modifier.size(34.dp)) { gameIcon(game) }
|
||||
Box(Modifier.width(1.dp).fillMaxHeight(.7f).background(Muted.copy(alpha = .4f)))
|
||||
Column(verticalArrangement = Arrangement.spacedBy(1.dp)) {
|
||||
Text(game.title.uppercase().takeIf { game == ArcadeGame.OrbMan } ?: game.title, color = Color.White, fontFamily = Marquee, fontSize = 18.sp, maxLines = 1)
|
||||
Text(game.tagline, color = Muted, fontSize = 11.sp, maxLines = 1)
|
||||
Text(game.title.uppercase().takeIf { game == ArcadeGame.OrbMan } ?: game.title, color = Color.White, fontFamily = Marquee, fontSize = 17.sp, lineHeight = 20.sp, maxLines = 1)
|
||||
Text(game.tagline, color = Muted, fontSize = 11.sp, lineHeight = 14.sp, maxLines = 1, overflow = androidx.compose.ui.text.style.TextOverflow.Ellipsis)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -504,7 +504,8 @@ internal fun OrbitArcade(modifier: Modifier, onPlaying: (Boolean) -> Unit) {
|
||||
// Every game, two to a row, then what you played last.
|
||||
Column(Modifier.weight(1f).fillMaxHeight(), verticalArrangement = Arrangement.spacedBy(6.dp)) {
|
||||
ArcadeGame.entries.chunked(2).forEachIndexed { row, pair ->
|
||||
Row(Modifier.fillMaxWidth().height(48.dp), horizontalArrangement = Arrangement.spacedBy(8.dp)) {
|
||||
// Tall enough for the name and its line in full (Paul, 5 November 2026: the line was clipped at 48).
|
||||
Row(Modifier.fillMaxWidth().height(56.dp), horizontalArrangement = Arrangement.spacedBy(8.dp)) {
|
||||
pair.forEachIndexed { i, game ->
|
||||
GameCard(game, Modifier.weight(1f).fillMaxHeight(), if (row == 0 && i == 0) first else null, if (row == 0) nav else null, { chosen = game }, { play(game) })
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user