|
|
@@ -918,6 +918,8 @@ export struct NavidromePage {
|
|
|
const restArtist: NavidromeRestArtist = {
|
|
|
id: artist.id,
|
|
|
name: artist.name,
|
|
|
+ albumCount: artist.albumCount,
|
|
|
+ songCount: artist.songCount,
|
|
|
coverUrl: coverUrl
|
|
|
};
|
|
|
results.push(restArtist);
|
|
|
@@ -933,6 +935,8 @@ export struct NavidromePage {
|
|
|
const restArtist: NavidromeRestArtist = {
|
|
|
id: artist.id,
|
|
|
name: artist.name,
|
|
|
+ albumCount: artist.albumCount,
|
|
|
+ songCount: artist.songCount,
|
|
|
coverUrl: coverUrl
|
|
|
};
|
|
|
results.push(restArtist);
|
|
|
@@ -1901,6 +1905,7 @@ export struct NavidromePage {
|
|
|
.opacity(0.6)
|
|
|
.maxLines(1)
|
|
|
.textOverflow({ overflow: TextOverflow.Ellipsis })
|
|
|
+ .visibility((artist.albumCount ?? 0) === 0 && (artist.songCount ?? 0) === 0 ? Visibility.None : Visibility.Visible)
|
|
|
}
|
|
|
.alignItems(HorizontalAlign.Start)
|
|
|
.padding({ right: 20 })
|
|
|
@@ -2044,6 +2049,12 @@ export struct NavidromePage {
|
|
|
const albumCount = artist.albumCount ?? 0;
|
|
|
const songCount = artist.songCount ?? 0;
|
|
|
const playCount = artist.playCount ?? 0;
|
|
|
+
|
|
|
+ // 如果专辑和歌曲数都为0,不显示元数据信息
|
|
|
+ if (albumCount === 0 && songCount === 0) {
|
|
|
+ return '';
|
|
|
+ }
|
|
|
+
|
|
|
return `专辑 ${albumCount} · 歌曲 ${songCount} `;
|
|
|
}
|
|
|
|