Add bio field to user model and update related components: Enhance leaderboard and profile features by including a bio field in user data. Update API routes, UI components, and validation logic to support bio input and display, improving user profiles and leaderboard entries.
This commit is contained in:
@@ -9,6 +9,7 @@ interface LeaderboardEntry {
|
||||
score: number;
|
||||
level: number;
|
||||
avatar: string | null;
|
||||
bio: string | null;
|
||||
}
|
||||
|
||||
export default async function LeaderboardPage() {
|
||||
@@ -23,6 +24,7 @@ export default async function LeaderboardPage() {
|
||||
score: true,
|
||||
level: true,
|
||||
avatar: true,
|
||||
bio: true,
|
||||
},
|
||||
});
|
||||
|
||||
@@ -32,6 +34,7 @@ export default async function LeaderboardPage() {
|
||||
score: user.score,
|
||||
level: user.level,
|
||||
avatar: user.avatar,
|
||||
bio: user.bio,
|
||||
}));
|
||||
|
||||
const backgroundImage = await getBackgroundImage(
|
||||
|
||||
Reference in New Issue
Block a user