Front; Song Lobby: Cpaters, Scores and layout

This commit is contained in:
Arthi-chaud
2022-09-04 16:06:05 +02:00
parent 62f1576a70
commit f6a0acb991
5 changed files with 854 additions and 707 deletions
+11 -11
View File
@@ -59,7 +59,7 @@ export default class API {
static async getSong(songId: number): Promise<Song> {
return delay(1).then(() => ({
title: "Song",
description: "A song",
description: "A very very very very very very very very very very very very very very very very very very very very very very very very good song",
album: "Album",
metrics: {},
id: songId
@@ -72,16 +72,16 @@ export default class API {
* @param songId the id to find the song
*/
static async getSongChapters(songId: number): Promise<Chapter[]> {
return [{
start: 0,
end: 100,
return [1, 2, 3, 4, 5].map((value) => ({
start: 100 * (value - 1),
end: 100 * value,
songId: songId,
name: "Chapter",
name: `Chapter ${value}`,
type: "chorus",
key_aspect: "rhythm",
difficulty: 1,
id: 1
}];
difficulty: value,
id: value * 10
}));
}
/**
@@ -89,11 +89,11 @@ export default class API {
* @param songId the id to find the song
*/
static async getSongHistory(songId: number): Promise<SongHistory[]> {
return [{
return [6, 1, 2, 3, 4, 5].map((value) => ({
songId: songId,
userId: 1,
score: 2
}];
score: value
}));
}
/**