1 Commits

Author SHA1 Message Date
arian 8a8a59d7f5 add songs option for default view selector in personal settings
Pipeline: Test, Lint, Build / Get version info (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Lint Go code (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Test Go code (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Test JS code (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Lint i18n files (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Check Docker configuration (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (darwin/amd64) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (darwin/arm64) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/386) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/amd64) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/arm/v5) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/arm/v6) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/arm/v7) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/arm64) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (linux/riscv64) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (windows/386) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build (windows/amd64) (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Push to GHCR (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Push to Docker Hub (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Cleanup digest artifacts (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Build Windows installers (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Package/Release (pull_request) Has been cancelled
Pipeline: Test, Lint, Build / Upload Linux PKG (pull_request) Has been cancelled
2026-04-01 16:06:10 -04:00
2 changed files with 12 additions and 1 deletions
+3
View File
@@ -225,6 +225,9 @@ const AlbumList = (props) => {
const type =
albumListType || localStorage.getItem('defaultView') || defaultAlbumList
const listParams = albumLists[type]
if (type === 'songs') {
return <Redirect to="/song" />
}
if (type === 'random') {
refresh()
}
+9 -1
View File
@@ -4,11 +4,19 @@ import albumLists, { defaultAlbumList } from '../album/albumLists'
export const SelectDefaultView = (props) => {
const translate = useTranslate()
const current = localStorage.getItem('defaultView') || defaultAlbumList
const choices = Object.keys(albumLists).map((type) => ({
const albumChoices = Object.keys(albumLists).map((type) => ({
id: type,
name: translate(`resources.album.lists.${type}`),
}))
const songChoice = {
id: 'songs',
name: translate('resources.song.name', { smart_count: 2 }),
}
const choices = [...albumChoices, songChoice]
return (
<SelectInput
{...props}