add experimental remove from queue action

+ show albumartist on TrackItem if artists == ""
+ add action to reset playlist page artists to prevent content flashes
+ remove use of defaultTrackItem
This commit is contained in:
geoffrey45
2022-08-15 10:25:34 +03:00
parent 1f374eeda1
commit e1c9cfa99b
17 changed files with 122 additions and 79 deletions
+5 -2
View File
@@ -20,8 +20,8 @@ export default defineStore("playlist-tracks", {
async fetchAll(playlistid: string) {
const playlist = await getPlaylist(playlistid);
this.info = playlist.info;
this.tracks = playlist.tracks;
this.info = playlist?.info || ({} as Playlist);
this.tracks = playlist?.tracks || [];
},
async fetchArtists(playlistid: string) {
@@ -35,5 +35,8 @@ export default defineStore("playlist-tracks", {
updatePInfo(info: Playlist) {
this.info = info;
},
resetArtists() {
this.artists = [];
},
},
});