-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtypes.ts
57 lines (51 loc) · 929 Bytes
/
types.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
export interface Event {
date: string;
venueName: string;
location: string;
buyUrl: string;
}
export interface Track {
title: string;
cover?: string;
count: number;
}
export interface SetList {
tracks: Track[];
from: string;
to: string;
totalTracks: number;
totalSetLists: number;
encores?: Record<string, number>;
}
export interface Link {
title: string;
uri: string;
cover: string;
previewUrl: string;
duration_ms: number;
}
interface Palette {
rgb: [number, number, number];
}
// returned by Spotify
export interface ArtistData {
name: string;
image: string | undefined;
tracks: Link[];
palette?: {
Vibrant: Palette;
DarkVibrant: Palette;
LightVibrant: Palette;
};
}
// returned by MusicBrainz
export interface ArtistInfo {
id: string;
name: string;
disambiguation: string;
"life-span": {
end: string;
begin: string;
ended: boolean;
};
}