diff --git a/src/lib/components/AlbumMenu.svelte b/src/lib/components/AlbumMenu.svelte index 1f3983849..e1d941ee0 100644 --- a/src/lib/components/AlbumMenu.svelte +++ b/src/lib/components/AlbumMenu.svelte @@ -6,6 +6,7 @@ MoreHorizontal, ListPlus, ListEnd, + ListMusic, Share2, Download, Link, @@ -16,6 +17,7 @@ interface Props { onPlayNext?: () => void; onPlayLater?: () => void; + onAddToPlaylist?: () => void; onShareQobuz?: () => void; onShareSonglink?: () => void; onDownload?: () => void; @@ -28,6 +30,7 @@ let { onPlayNext, onPlayLater, + onAddToPlaylist, onShareQobuz, onShareSonglink, onDownload, @@ -54,9 +57,10 @@ const menuId = Symbol('album-menu'); const hasQueue = $derived(!!(onPlayNext || onPlayLater)); + const hasLibrary = $derived(!!onAddToPlaylist); const hasShare = $derived(!!(onShareQobuz || onShareSonglink)); const hasDownload = $derived(!!onDownload || isAlbumFullyDownloaded); - const hasMenu = $derived(hasQueue || hasShare || hasDownload); + const hasMenu = $derived(hasQueue || hasLibrary || hasShare || hasDownload); function closeMenu() { isOpen = false; @@ -261,7 +265,18 @@ {/if} {/if} - {#if hasQueue && (hasShare || hasDownload)} + {#if hasQueue && (hasLibrary || hasShare || hasDownload)} +
+ {/if} + + {#if hasLibrary} + + {/if} + + {#if hasLibrary && (hasShare || hasDownload)} {/if}