From 701f6d423dc2fd9aeb859c30f3380743bafb21b6 Mon Sep 17 00:00:00 2001 From: Sayem Chowdhury Date: Wed, 3 Mar 2021 01:18:06 +0600 Subject: [PATCH] update album search type --- src/types.ts | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/src/types.ts b/src/types.ts index 694528a..3fa329d 100644 --- a/src/types.ts +++ b/src/types.ts @@ -108,6 +108,26 @@ export interface trackType extends songType { TRACK_POSITION?: number; } +interface albumTypeMinimal { + ALB_ID: string; + ALB_TITLE: string; + ALB_PICTURE: string; + ARTISTS: artistType[]; + AVAILABLE: boolean; + VERSION: string; // '' + ART_ID: string; + ART_NAME: string; + EXPLICIT_ALBUM_CONTENT: { + EXPLICIT_LYRICS_STATUS: number; // 1 + EXPLICIT_COVER_STATUS: number; //2 + }; + PHYSICAL_RELEASE_DATE: string; + TYPE: string; // '0' + ARTIST_IS_DUMMY: boolean; + NUMBER_TRACK: number; // '1'; + __TYPE__: 'album'; +} + export interface albumType { ALB_CONTRIBUTORS: { main_artist: string[]; // ['Avicii'] @@ -148,6 +168,15 @@ export interface albumTracksType { next?: number; } +interface albumSearchType { + data: albumTypeMinimal[]; + count: number; + total: number; + filtered_count: number; + filtered_items: number[]; + next: number; +} + export interface playlistInfo { PLAYLIST_ID: string; // '4523119944' DESCRIPTION?: string; // '' @@ -237,7 +266,7 @@ export interface searchType { 'USER', 'LYRICS', ]; - ALBUM: albumTracksType; + ALBUM: albumSearchType; ARTIST: albumTracksType; TRACK: albumTracksType; PLAYLIST: albumTracksType;