Skip to content

Add individual track download (closes #100)#103

Closed
Mounstroya wants to merge 2 commits into
ghenry22:masterfrom
Mounstroya:feature/download-individual-tracks
Closed

Add individual track download (closes #100)#103
Mounstroya wants to merge 2 commits into
ghenry22:masterfrom
Mounstroya:feature/download-individual-tracks

Conversation

@Mounstroya
Copy link
Copy Markdown

Allows users to download single songs for offline playback.

Changes:

  • Long-press any track → more options sheet now shows Download/Remove Download
  • Now Playing screen shows a download button next to the ♥ icon
  • Download status indicator (downloaded icon) already worked per-song via useDownloadStatus('song', id) — no changes needed in TrackRow/SongRow

Implementation:

  • New enqueueSongDownload(song) in musicCacheService — stores the track under its own ID as itemId
  • DownloadButton extended to accept type: 'song'
  • MoreOptionsSheet canDownload() now includes songs

Closes #100

Allow single songs to be downloaded for offline playback via the
long-press more-options sheet. Previously only albums and playlists
could be downloaded.

- Add 'song' to CachedMusicItem and DownloadQueueItem type unions
- Add enqueueSongDownload(song) to musicCacheService
- Export enqueueSongDownload from moreOptionsService
- Update canDownload() in MoreOptionsSheet to include songs
- Update handleDownload to call enqueueSongDownload for songs
- Update music-cache-browser to display 'Song' label for song items
- Update redownloadItem to handle the new 'song' type
- Add tests for enqueueSongDownload

Closes ghenry22#100
Show a per-track download button in the Now Playing screen alongside
the heart icon so users can cache the current song without leaving
the player.

- Extend DownloadButton to accept type 'song' (caller provides onDownload)
- Add PlayerDownloadButton component to player-view
- Disable download trigger in offline mode (status still visible)
- Mock DownloadButton in player-view tests
@Mounstroya
Copy link
Copy Markdown
Author


Re: CI translation failure

The translation validation errors (activeShares, logging, serverAccount, etc.) are pre-existing in the master branch and are not related to this PR.

My branch makes zero changes to any src/i18n/ file — you can verify with:

git diff master -- src/i18n/

These keys exist in en.json on master but are missing from the other locale files. The CI would fail the same way on a fresh checkout of master.

@ghenry22
Copy link
Copy Markdown
Owner

Yeh just ignore the translation thing, I have pushed a rule update that just warns rather than bombing CI on translation gaps.

Thanks for the PR, I will review this but I need to also implement song based browsing otherwise there is not a good way to actually browse and play the offline songs.

Song browsing and downloading is towards the top of my todo list, I have an update with a bunch of stability work and fixes in it to go out shortly then this will be worked on for the next update after that.

I am trying to push updates out roughly once a week so I don't burn all my CI credit!

@Mounstroya
Copy link
Copy Markdown
Author

Hey! Thanks for the update, the recent changes look great.

I was wondering if you have a place where you track upcoming features or things you're currently working on? I'd really love to contribute more, and it would help me focus on areas that are actually useful for the project 🙂

I was quite excited about my previous contribution 😿 , so I'd love to keep helping

@ghenry22
Copy link
Copy Markdown
Owner

Hey! Thanks for the update, the recent changes look great.

I was wondering if you have a place where you track upcoming features or things you're currently working on? I'd really love to contribute more, and it would help me focus on areas that are actually useful for the project 🙂

I was quite excited about my previous contribution 😿 , so I'd love to keep helping

Thanks for taking the time and effort to make a PR for this. I already had a plan and work underway for how I wanted to handle surfacing individual songs in the library list and as downloads. This work has all been completed and is now in github, it will roll out in the next release.

For a list of features it is generally what is logged on github and then things from my own testing that roll in as well. I do have a specific way that I want to handle somethings (particularly bigger features like carplay/android auto, gapless playback etc).

While I might not merge every PR they are still extremely useful as a reference when I do implement the functionality and I certainly appreciate the community contributions!

@ghenry22 ghenry22 closed this May 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add opportunity to download single track (from play view, context menu)

2 participants