diff --git a/android/app/src/main/java/com/fabledsword/minstrel/shared/widgets/CoverTile.kt b/android/app/src/main/java/com/fabledsword/minstrel/shared/widgets/CoverTile.kt index b51ef75f..1e16bdf4 100644 --- a/android/app/src/main/java/com/fabledsword/minstrel/shared/widgets/CoverTile.kt +++ b/android/app/src/main/java/com/fabledsword/minstrel/shared/widgets/CoverTile.kt @@ -23,8 +23,12 @@ import com.fabledsword.minstrel.theme.FabledSwordFlatTokens * ServerImage + fallback structure was identical at all three sites. * * [overlay] is a `BoxScope` slot for things drawn on top of the cover - * (e.g. the `VariantPill` system-playlist label) — callers can use - * `Modifier.align(...)` inside it. + * (e.g. the `VariantPill` system-playlist label, the play button) — + * callers can use `Modifier.align(...)` inside it. The overlay sits on + * an outer, UN-clipped box so corner-anchored widgets are not cut off by + * [shape]: a `BottomEnd` play button on a `CircleShape` avatar falls in + * the square's corner, outside the circle, and would otherwise be clipped + * away. Only the artwork + background are clipped to [shape]. */ @Composable fun CoverTile( @@ -38,18 +42,23 @@ fun CoverTile( overlay: @Composable BoxScope.() -> Unit = {}, ) { Box( - modifier = modifier - .size(size) - .clip(shape) - .background(background), + modifier = modifier.size(size), contentAlignment = Alignment.Center, ) { - ServerImage( - url = url, - contentDescription = contentDescription, - modifier = Modifier.fillMaxSize(), + Box( + modifier = Modifier + .fillMaxSize() + .clip(shape) + .background(background), + contentAlignment = Alignment.Center, ) { - fallback() + ServerImage( + url = url, + contentDescription = contentDescription, + modifier = Modifier.fillMaxSize(), + ) { + fallback() + } } overlay() }