feat(dash): Revamp dashboard UI with glassmorphism and real bot data

This commit is contained in:
syntaxbullet
2026-01-08 20:58:57 +01:00
parent 8ebaf7b4ee
commit fff90804c0
14 changed files with 376 additions and 213 deletions

View File

@@ -37,6 +37,7 @@ describe("dashboardService", () => {
describe("getActiveUserCount", () => {
test("should return active user count from database", async () => {
mockSelect.mockImplementationOnce(() => ({
// @ts-ignore ts(2322)
from: mock(() => ({
where: mock(() => Promise.resolve([{ count: "5" }])),
})),
@@ -48,7 +49,9 @@ describe("dashboardService", () => {
});
test("should return 0 when no users found", async () => {
mockSelect.mockImplementationOnce(() => ({
// @ts-ignore ts(2322)
from: mock(() => ({
where: mock(() => Promise.resolve([{ count: "0" }])),
})),

View File

@@ -1,4 +1,8 @@
export interface DashboardStats {
bot: {
name: string;
avatarUrl: string | null;
};
guilds: {
count: number;
changeFromLastMonth?: number;
@@ -32,6 +36,10 @@ export interface RecentEvent {
}
export interface ClientStats {
bot: {
name: string;
avatarUrl: string | null;
};
guilds: number;
ping: number;
cachedUsers: number;