feat(i18n, agents, players): enhance localization and improve agent and player management interfaces
Some checks failed
lotteryadmin CI / build (push) Has been cancelled

Updated localization files for English and Nepali, adding new entries and refining existing translations for better clarity. Enhanced the agent management interface with improved delegation features and child agent creation prompts. Improved player management functionalities, including confirmation dialogs for player actions and better handling of player creation and editing processes.
This commit is contained in:
2026-06-16 17:08:12 +08:00
parent a020e34a7d
commit b924496a26
25 changed files with 4273 additions and 3239 deletions

42
src/app/error.tsx Normal file
View File

@@ -0,0 +1,42 @@
"use client";
import { useEffect } from "react";
import Link from "next/link";
export default function AdminError({
error,
reset,
}: {
error: Error & { digest?: string };
reset: () => void;
}): React.ReactElement {
useEffect(() => {
console.error("[AdminError]", error);
}, [error]);
return (
<div className="flex min-h-[60vh] flex-col items-center justify-center gap-4 p-6 text-center">
<h1 className="text-xl font-semibold"></h1>
<p className="max-w-md text-sm text-muted-foreground">
</p>
{process.env.NODE_ENV === "development" ? (
<pre className="max-w-xl overflow-auto rounded-md bg-muted p-3 text-left text-xs">
{error.message}
</pre>
) : null}
<div className="flex gap-3">
<button
type="button"
onClick={reset}
className="rounded-md border px-4 py-2 text-sm"
>
</button>
<Link href="/admin" className="rounded-md bg-primary px-4 py-2 text-sm text-primary-foreground">
</Link>
</div>
</div>
);
}

13
src/app/not-found.tsx Normal file
View File

@@ -0,0 +1,13 @@
import Link from "next/link";
export default function AdminNotFound(): React.ReactElement {
return (
<div className="flex min-h-[60vh] flex-col items-center justify-center gap-4 p-6 text-center">
<h1 className="text-xl font-semibold"></h1>
<p className="text-sm text-muted-foreground"></p>
<Link href="/admin" className="rounded-md bg-primary px-4 py-2 text-sm text-primary-foreground">
</Link>
</div>
);
}