Revert "Add missing admin action files and navigation links"

This reverts commit 41be6835bf.
This commit is contained in:
Simo committed 2026-07-11 20:37:56 +02:00
1 parent 4a1e1115b3
commit 4d515bc400
338 files changed
+5949 -28144

No files matched your search

+15 -5
View File
@@ -20,7 +20,8 @@ type DrawBadge = {
badgeDesc: string;
};
const BOUGHT_NOTE = (code: string) => `Badge "${code}" has been added to your inventory. Enjoy!`;
const BOUGHT_NOTE = (code: string) =>
`Badge "${code}" has been added to your inventory. Enjoy!`;
const ERROR_NOTE: Record<string, string> = {
invalid: "That badge is no longer available.",
@@ -105,7 +106,10 @@ export default async function DrawBadgePage({
</p>
) : null}
{error ? (
<p role="alert" style={{ margin: "1rem 0 0", fontWeight: 700, color: "var(--color-danger)" }}>
<p
role="alert"
style={{ margin: "1rem 0 0", fontWeight: 700, color: "var(--color-danger)" }}
>
{getErrorNote(error)}
</p>
) : null}
@@ -114,11 +118,15 @@ export default async function DrawBadgePage({
<ContentCard
icon="🏅"
title="Available badges"
subtitle={badges.length > 0 ? `${badges.length} badge(s) available` : undefined}
subtitle={
badges.length > 0 ? `${badges.length} badge(s) available` : undefined
}
padded={badges.length === 0}
>
{badges.length === 0 ? (
<EmptyState icon="🎨">No badges have been published yet. Check back soon!</EmptyState>
<EmptyState icon="🎨">
No badges have been published yet. Check back soon!
</EmptyState>
) : (
<div className="card-grid sm-2 lg-3" style={{ padding: "1rem" }}>
{badges.map((b) => {
@@ -168,7 +176,9 @@ export default async function DrawBadgePage({
</div>
</div>
{b.badgeDesc ? <p style={{ margin: "0 0 0.85rem" }}>{b.badgeDesc}</p> : null}
{b.badgeDesc ? (
<p style={{ margin: "0 0 0.85rem" }}>{b.badgeDesc}</p>
) : null}
<form action={buyBadge}>
<input type="hidden" name="id" value={String(b.id)} />