diff --git a/DeepDrftPublic.Client/Pages/TrackDetail.razor b/DeepDrftPublic.Client/Pages/TrackDetail.razor index 73884e8..4c10ec1 100644 --- a/DeepDrftPublic.Client/Pages/TrackDetail.razor +++ b/DeepDrftPublic.Client/Pages/TrackDetail.razor @@ -64,9 +64,17 @@ else if (ViewModel.Track is not null)
- - - + @if (!string.IsNullOrEmpty(track.ImagePath)) + { + + } + else + { + + + + }
@if (hasMeta) diff --git a/DeepDrftPublic/wwwroot/styles/deepdrft-styles.css b/DeepDrftPublic/wwwroot/styles/deepdrft-styles.css index ce30251..9d182be 100644 --- a/DeepDrftPublic/wwwroot/styles/deepdrft-styles.css +++ b/DeepDrftPublic/wwwroot/styles/deepdrft-styles.css @@ -317,6 +317,14 @@ h2, h3, h4, h5, h6, font-size: 72px; } +/* Album art fills the square frame; background-size:cover handles any aspect ratio. */ +.deepdrft-track-detail-cover-art { + height: 100%; + background-size: cover; + background-position: center; + background-repeat: no-repeat; +} + .deepdrft-track-detail-masthead { display: flex; flex-direction: column;