managarten/apps-archived/mukke/apps/mobile/components/ArtistList.tsx
Till JS 7a56699d45 feat(mukke): rename LightWrite to Mukke and add music library, player, playlists
Combines LightWrite (beat/lyrics editor) and Mukke (iOS music player) into
a single web-based music workspace app. Archives the old Mukke mobile app.

- Rename: @lightwrite/* → @mukke/*, all branding, configs, Dockerfiles
- New DB schemas: songs, playlists, playlist_songs + songId FK on projects
- New backend modules: SongModule, PlaylistModule, LibraryModule
- New web: app shell with sidebar, library (songs/albums/artists/genres),
  web player (queue/shuffle/repeat/MediaSession), playlists, search,
  upload, dashboard, album/artist/genre detail pages
- Auth: add forgot-password + reset-password pages, extend auth store
- Tests: 40 backend unit tests (song, playlist, library services)
- Config: env generation, MinIO bucket, docker-compose prod, cloudflare
- Docs: update CLAUDE.md, auth guidelines with SvelteKit checklist

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:55:56 +01:00

43 lines
1,010 B
TypeScript

import { useRouter } from 'expo-router';
import { FlatList } from 'react-native';
import type { Artist } from '~/types';
import { Artwork } from './Artwork';
import { EmptyState } from './EmptyState';
import { ListItem } from './ListItem';
interface ArtistListProps {
artists: Artist[];
}
export function ArtistList({ artists }: ArtistListProps) {
const router = useRouter();
if (artists.length === 0) {
return (
<EmptyState
icon="person-outline"
title="Keine Künstler"
message="Importierte Songs werden nach Künstlern gruppiert."
/>
);
}
return (
<FlatList
data={artists}
keyExtractor={(item) => item.name}
contentContainerStyle={{ paddingBottom: 100 }}
renderItem={({ item }) => (
<ListItem
title={item.name}
subtitle={`${item.songCount} Songs · ${item.albumCount} Alben`}
left={<Artwork uri={null} size={44} rounded />}
onPress={() => router.push(`/artist/${encodeURIComponent(item.name)}`)}
showChevron
/>
)}
/>
);
}