feat: Integrate new dashboard design and components, remove old dashboard routes, and update dependencies.

This commit is contained in:
2026-02-10 15:00:11 +08:00
parent 1c2ef98dcd
commit 48cf6c44f5
82 changed files with 6896 additions and 261 deletions

View File

@@ -0,0 +1,51 @@
import {
Badge as MantineBadge,
type BadgeProps as MantineBadgeProps,
} from "@mantine/core";
import { cn } from "./utils";
interface BadgeProps extends MantineBadgeProps {
variant?: "default" | "secondary" | "destructive" | "success";
}
const Badge = ({
className,
variant = "default",
children,
...props
}: BadgeProps) => {
let mantineVariant: MantineBadgeProps["variant"];
let mantineColor: MantineBadgeProps["color"];
switch (variant) {
case "secondary":
mantineVariant = "light";
mantineColor = "gray";
break;
case "destructive":
mantineVariant = "filled";
mantineColor = "red";
break;
case "success":
mantineVariant = "filled";
mantineColor = "green";
break;
default:
mantineVariant = "filled";
mantineColor = "blue"; // Placeholder, should align with primary color
break;
}
return (
<MantineBadge
variant={mantineVariant}
color={mantineColor}
className={cn(className)}
{...props}
>
{children}
</MantineBadge>
);
};
export { Badge };