improve jellyfin participants

This commit is contained in:
Kendall Garner 2025-10-10 19:32:11 -07:00
parent 452803fc72
commit 6733047942
No known key found for this signature in database
GPG key ID: 9355F387FE765C94
2 changed files with 7 additions and 1 deletions

View file

@ -81,7 +81,7 @@ const formatArtists = (artists: null | RelatedArtist[] | undefined) =>
{artist.name || '—'}
</Text>
) : (
<Text overflow="visible" size="md">
<Text component="span" overflow="visible" size="md">
{artist.name || '-'}
</Text>
)}

View file

@ -127,12 +127,18 @@ const getPlaylistCoverArtUrl = (args: { baseUrl: string; item: JFPlaylist; size:
type AlbumOrSong = z.infer<typeof jfType._response.album> | z.infer<typeof jfType._response.song>;
const KEYS_TO_OMIT = new Set(['AlbumArtist', 'Artist']);
const getPeople = (item: AlbumOrSong): null | Record<string, RelatedArtist[]> => {
if (item.People) {
const participants: Record<string, RelatedArtist[]> = {};
for (const person of item.People) {
const key = person.Type || '';
if (KEYS_TO_OMIT.has(key)) {
continue;
}
const item: RelatedArtist = {
// for other roles, we just want to display this and not filter.
// filtering (and links) would require a separate field, PersonIds