[INT-V2-002] Use TrackStatus enum in types/api.ts
- Replace string literal union with TrackStatus enum - Import TrackStatus from @/features/tracks/types/track - Improves type-safety for Track.status field
This commit is contained in:
parent
a205768c09
commit
27982e807f
1 changed files with 3 additions and 1 deletions
|
|
@ -1,4 +1,6 @@
|
|||
// Types de base pour l'API
|
||||
import { TrackStatus } from '@/features/tracks/types/track';
|
||||
|
||||
export interface User {
|
||||
// UUID from backend - always string
|
||||
id: string;
|
||||
|
|
@ -71,7 +73,7 @@ export interface Track {
|
|||
cover_art_path?: string; // Backend uses cover_art_path (not cover_art_url)
|
||||
is_public: boolean;
|
||||
// INT-TYPE-004: TrackStatus enum aligned with backend
|
||||
status: 'uploading' | 'processing' | 'completed' | 'failed'; // Use TrackStatus enum from features/tracks/types/track.ts
|
||||
status: TrackStatus;
|
||||
status_message?: string;
|
||||
stream_status: 'pending' | 'processing' | 'ready' | 'error';
|
||||
stream_manifest_url?: string;
|
||||
|
|
|
|||
Loading…
Reference in a new issue