added event helpers to ui libary, added Badge component, reordered Dashboard Components, splitted Event Admin page

This commit is contained in:
PxlLoewe
2025-03-07 14:16:19 -07:00
parent c1f1ad47b7
commit 829e78a47d
25 changed files with 465 additions and 355 deletions

View File

@@ -0,0 +1,28 @@
import { Badge } from "@repo/ui";
import { Award } from "lucide-react";
import { getServerSession } from "../../api/auth/[...nextauth]/auth";
export const Badges = async () => {
const session = await getServerSession();
if (!session) return null;
return (
<div className="card bg-base-200 shadow-xl mb-4 col-span-6 xl:col-span-3">
<div className="card-body">
<h2 className="card-title justify-between">
<span className="card-title">
<Award className="w-4 h-4" /> Verdiente Abzeichen
</span>
</h2>
{session.user.badges.map((badge) => {
return (
<div className="badge badge-primary badge-outline">
<Badge name={badge} />
</div>
);
})}
</div>
</div>
);
};