From 774590687517709bd60458a8c131b50b55220bfa Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 28 Oct 2023 18:15:46 +0100 Subject: [PATCH] add stars and diff to embed --- src/app/leaderboard/[id]/[page]/page.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/app/leaderboard/[id]/[page]/page.tsx b/src/app/leaderboard/[id]/[page]/page.tsx index 66670b7..00498f5 100644 --- a/src/app/leaderboard/[id]/[page]/page.tsx +++ b/src/app/leaderboard/[id]/[page]/page.tsx @@ -1,6 +1,7 @@ import Leaderboard from "@/components/leaderboard/Leaderboard"; import { formatNumber } from "@/utils/number"; import { ScoreSaberAPI } from "@/utils/scoresaber/api"; +import { scoresaberDifficultyNumberToName } from "@/utils/songUtils"; import { formatTime } from "@/utils/timeUtils"; import { Metadata } from "next"; @@ -29,6 +30,10 @@ export async function generateMetadata({ }). Mapper: ${leaderboard.levelAuthorName} + Stars: ${leaderboard.stars} + Difficulty: ${scoresaberDifficultyNumberToName( + leaderboard.difficulty.difficulty, + )} Total plays: ${formatNumber(leaderboard.plays)} Created: ${formatTime(new Date(leaderboard.createdDate))} `,