fix: Only show single line for tracks without artists or albums

This commit is contained in:
Lei Nelissen
2022-11-13 12:09:36 +01:00
parent 0ffc5b6489
commit 7ed389ead6
3 changed files with 21 additions and 15 deletions

View File

@@ -142,12 +142,14 @@ export default function Queue({ header }: Props) {
>
{track.title}
</Text>
<TextHalfOpacity
style={currentIndex === index ? { color: THEME_COLOR, fontWeight: '400' } : undefined}
numberOfLines={1}
>
{track.artist}{track.album && ' — ' + track.album}
</TextHalfOpacity>
{(track.artist || track.album) && (
<TextHalfOpacity
style={currentIndex === index ? { color: THEME_COLOR, fontWeight: '400' } : undefined}
numberOfLines={1}
>
{track.artist}{track.album && ' — ' + track.album}
</TextHalfOpacity>
)}
</View>
<View style={{ marginLeft: 'auto', marginRight: 8 }}>
<TextHalfOpacity