Repository navigation
feat(web): find in a playlist, sort it, and a compact view - #1431
Open
saliltimalsina wants to merge 1 commit into
Open
saliltimalsina wants to merge 1 commit into
saliltimalsina wants to merge 1 commit into
Conversation
A toolbar above a playlist's songs: Find in playlist (title, artist or album, any word order, accents ignored), Sort by (custom order, title, artist, album, shortest or longest first; remembered per playlist) and list or compact rows (remembered for all). Finding or sorting loads the rest of a long playlist first, and playing from a sorted list queues it in that order.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
A toolbar above a playlist's songs, as Spotify's playlist page has:
Finding or sorting loads the rest of a long playlist first ("Loading the rest of the playlist…"), so it covers every song, not just the first page. Play, Shuffle and playing a row follow the order shown.
How
playlistView.ts: purefilterTracksandsortTracks. Sorting is stable, usesIntl.Collatorwith numeric compare, and puts songs with no album or no duration last.playlistPrefs.ts:localStorage, with nothing breaking when storage is unavailable.TrackListtakescompact. The virtualizer's estimate follows it and re-measures when it changes.type="text",role="searchbox". The/shortcut focuses the firstinput[type="search"], and that should stay the site search.No new dependencies.
Testing
pnpm typecheck,pnpm test(7 new tests) and the app build pass.