Files
Psychotoxical-psysonic/src/features/artist/index.ts
T
Psychotoxical 36b0042d9a refactor(decouple): move coerceOpenArtistRefs to lib/api (off artist feature)
First step of decoupling the audio core from feature imports. coerceOpenArtist
Refs is a pure Subsonic-response normalizer (one-object-vs-array quirk) that was
mis-membered in features/artist but consumed by the audio core (songToTrack,
trackArtistRefs) and others. Relocate it beside its SubsonicOpenArtistRef type in
lib/api/; drop the artist-barrel re-export; repoint the 4 barrel consumers.

Removes the @/features/artist runtime edge from the audio core (utils/playback)
entirely. tsc 0, lint 0/0, suite 319/2353 green.

(composerBrowseSessionStore's ALL_SENTINEL import from @/features/artist remains
— that's a non-audio global browse store, separate from this decouple.)
2026-06-30 08:53:56 +02:00

40 lines
2.2 KiB
TypeScript

/**
* Artist feature — the Artists overview + ArtistDetail (both lazy via their deep
* `pages/*` paths, not re-exported), artist cards/rows/avatars, the detail hero +
* similar-artists + top-tracks UI, the artist Subsonic API, browse catalog/
* filter/scroll hooks, per-artist offline status, and the open-artist-ref nav
* cluster. `sortArtistAlbums` moved in from `utils/library/` (artist-only sort,
* not the shared index query engine).
*
* Stays OUT (other owners): `deriveAlbumHeaderArtistRefs` (album header),
* `playArtistShuffled` + `trackArtistRefs` (playback/track helpers), the
* `*ContextItems`/`*ToPlaylistSubmenu` items (the cross-cutting context-menu
* subsystem, shared with album), and `PlaylistArtistCell` (playlist).
*/
export * from './hooks/useArtistDetailData';
export * from './hooks/useArtistInfoBatch';
export * from './hooks/useArtistOfflineState';
export * from './hooks/useArtistsBrowseCatalog';
export * from './hooks/useArtistsBrowseFilters';
export * from './hooks/useArtistsBrowseScrollReset';
export * from './hooks/useArtistsBrowseScrollRestore';
export * from './hooks/useArtistsFiltering';
export * from './hooks/useArtistSimilarArtists';
export * from './hooks/useArtistsInfiniteScroll';
export * from './hooks/useBrowseArtistTextSearch';
export * from './hooks/useNavigateToArtist';
export * from './store/artistAlbumYearSortStore';
export * from './store/artistBrowseSessionStore';
export * from './store/artistLayoutStore';
export * from './utils/artistsHelpers';
export * from './utils/runArtistDetailActions';
export * from './utils/runArtistDetailPlay';
export * from './utils/sortArtistAlbums';
export { OpenArtistRefInline } from './components/OpenArtistRefInline';
export { default as ArtistCardLocal } from './components/ArtistCardLocal';
export { default as ArtistDetailHero } from './components/ArtistDetailHero';
export { default as ArtistDetailSimilarArtists } from './components/ArtistDetailSimilarArtists';
export { default as ArtistDetailTopTracks } from './components/ArtistDetailTopTracks';
export { default as ArtistRow } from './components/ArtistRow';
export { default as ArtistTopTrackCover } from './components/ArtistTopTrackCover';