Merge pull request #4906 from sir-wilhelm/playlist-sorted

When adding items to playlist, sort the playlist sections alphabetically.
This commit is contained in:
advplyr 2025-12-21 14:01:08 -06:00 committed by GitHub
commit ebcb122eb8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -97,7 +97,10 @@ export default {
...playlist
}
})
.sort((a, b) => (a.isItemIncluded ? -1 : 1))
.sort((a, b) => {
if (a.isItemIncluded !== b.isItemIncluded) return a.isItemIncluded ? -1 : 1
return a.name.localeCompare(b.name)
})
},
isBatch() {
return this.selectedPlaylistItems.length > 1