diff --git a/CHANGELOG.md b/CHANGELOG.md index 59de17c0..71b54820 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -651,6 +651,12 @@ Foundational work: faster reviews, narrower diffs, and a safety net under the pa * Collapsing and re-expanding **Settings → Audio → Equalizer** sometimes left the curve area blank: `ResizeObserver` does not reliably fire for the `display: none → block` transition the surrounding `
` triggers, so the redraw that depends on it never ran on the second open. A `toggle` listener on the parent `
` now redraws explicitly on open. +### Library — empty-state on Mainstage, Albums, New Releases and Random Albums + +**By [@Psychotoxical](https://github.com/Psychotoxical), thanks to zunoz for the report on the Psysonic Discord, PR [#750](https://github.com/Psychotoxical/psysonic/pull/750)** + +* Selecting an empty library no longer leaves these pages as a fully blank canvas. A shared `common.libraryEmpty` message ("Your library is empty.") added across all nine locales is shown in place of the empty rails/grids. Pages that already had a dedicated empty-state (Artists, Genres, Composers, Playlists, Favorites, Most Played, Lossless Albums, Label Albums, Internet Radio) keep their per-page wording. On Albums and New Releases, an active genre / year / starred / compilation filter still shows the regular filtered-results behaviour rather than the library-empty message. + ## [1.45.0] - 2026-05-04 ## Added diff --git a/src/locales/de/common.ts b/src/locales/de/common.ts index 3fb487aa..7eb66970 100644 --- a/src/locales/de/common.ts +++ b/src/locales/de/common.ts @@ -63,4 +63,5 @@ export const common = { more: 'mehr', yearRange: 'Jahresbereich', clearAll: 'Alles zurücksetzen', + libraryEmpty: 'Deine Bibliothek ist leer.', }; diff --git a/src/locales/en/common.ts b/src/locales/en/common.ts index 36c5a208..308859bb 100644 --- a/src/locales/en/common.ts +++ b/src/locales/en/common.ts @@ -63,4 +63,5 @@ export const common = { more: 'more', yearRange: 'Year Range', clearAll: 'Clear all', + libraryEmpty: 'Your library is empty.', }; diff --git a/src/locales/es/common.ts b/src/locales/es/common.ts index 3ab8dd9d..f8475fd3 100644 --- a/src/locales/es/common.ts +++ b/src/locales/es/common.ts @@ -53,4 +53,5 @@ export const common = { more: 'más', yearRange: 'Rango de años', clearAll: 'Limpiar todo', + libraryEmpty: 'Tu biblioteca está vacía.', }; diff --git a/src/locales/fr/common.ts b/src/locales/fr/common.ts index 6cdd830b..37da0ae8 100644 --- a/src/locales/fr/common.ts +++ b/src/locales/fr/common.ts @@ -53,4 +53,5 @@ export const common = { more: 'plus', yearRange: 'Plage d\'années', clearAll: 'Tout effacer', + libraryEmpty: 'Votre bibliothèque est vide.', }; diff --git a/src/locales/nb/common.ts b/src/locales/nb/common.ts index 695f0ef2..57880ef0 100644 --- a/src/locales/nb/common.ts +++ b/src/locales/nb/common.ts @@ -53,4 +53,5 @@ export const common = { more: 'mer', yearRange: 'Årsspenn', clearAll: 'Tøm alt', + libraryEmpty: 'Biblioteket ditt er tomt.', }; diff --git a/src/locales/nl/common.ts b/src/locales/nl/common.ts index 9c9c3c6b..84c5c164 100644 --- a/src/locales/nl/common.ts +++ b/src/locales/nl/common.ts @@ -53,4 +53,5 @@ export const common = { more: 'meer', yearRange: 'Jaarbereik', clearAll: 'Alles wissen', + libraryEmpty: 'Je bibliotheek is leeg.', }; diff --git a/src/locales/ro/common.ts b/src/locales/ro/common.ts index b472daf2..d5705219 100644 --- a/src/locales/ro/common.ts +++ b/src/locales/ro/common.ts @@ -63,4 +63,5 @@ export const common = { more: 'mai mult', yearRange: 'Interval de an', clearAll: 'Golește tot', + libraryEmpty: 'Biblioteca ta este goală.', }; diff --git a/src/locales/ru/common.ts b/src/locales/ru/common.ts index 24dc0474..961885f8 100644 --- a/src/locales/ru/common.ts +++ b/src/locales/ru/common.ts @@ -53,4 +53,5 @@ export const common = { more: 'еще', yearRange: 'Диапазон лет', clearAll: 'Очистить всё', + libraryEmpty: 'Ваша библиотека пуста.', }; diff --git a/src/locales/zh/common.ts b/src/locales/zh/common.ts index 085ce954..a7c4ac51 100644 --- a/src/locales/zh/common.ts +++ b/src/locales/zh/common.ts @@ -53,4 +53,5 @@ export const common = { more: '更多', yearRange: '年份范围', clearAll: '清除全部', + libraryEmpty: '你的音乐库是空的。', }; diff --git a/src/pages/Albums.tsx b/src/pages/Albums.tsx index 84752eea..a2f1a559 100644 --- a/src/pages/Albums.tsx +++ b/src/pages/Albums.tsx @@ -310,6 +310,10 @@ export default function Albums() {
+ ) : !loading && albums.length === 0 && !genreFiltered && !yearActive && !starredOnly && compFilter === 'all' ? ( +
+ {t('common.libraryEmpty')} +
) : ( <> {!perfFlags.disableMainstageGridCards && ( diff --git a/src/pages/Home.tsx b/src/pages/Home.tsx index ab827017..896520a8 100644 --- a/src/pages/Home.tsx +++ b/src/pages/Home.tsx @@ -183,6 +183,16 @@ export default function Home() { const homeLiteArtworkFx = perfFlags.disableHomeArtworkFx; const homeFlatArtworkClip = perfFlags.disableHomeArtworkClip; + // Treat the library as empty when every album endpoint returned zero. The + // song/artist rails can be empty for non-empty libraries (rare server quirks), + // so they don't count toward this signal. + const libraryEmpty = + !loading && + recent.length === 0 && + random.length === 0 && + mostPlayed.length === 0 && + recentlyPlayed.length === 0 && + starred.length === 0; return (
{!perfFlags.disableMainstageHero && isVisible('hero') && } @@ -192,6 +202,10 @@ export default function Home() {
+ ) : libraryEmpty ? ( +
+ {t('common.libraryEmpty')} +
) : ( <> {!homeAlbumRowsDisabled && isVisible('recent') && ( diff --git a/src/pages/NewReleases.tsx b/src/pages/NewReleases.tsx index 05fa083d..7bd00de1 100644 --- a/src/pages/NewReleases.tsx +++ b/src/pages/NewReleases.tsx @@ -178,6 +178,10 @@ export default function NewReleases() {
+ ) : !loading && albums.length === 0 && !filtered ? ( +
+ {t('common.libraryEmpty')} +
) : ( <>
+ ) : !loading && albums.length === 0 ? ( +
+ {t('common.libraryEmpty')} +
) : (