Add account restrictions, appeals, and admin moderation tools
This commit is contained in:
67
app/ban/appeal/page.module.css
Normal file
67
app/ban/appeal/page.module.css
Normal file
@@ -0,0 +1,67 @@
|
||||
.heading {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
gap: 12px;
|
||||
}
|
||||
.heading h2,
|
||||
.heading h3 {
|
||||
margin: 0;
|
||||
}
|
||||
.heading {
|
||||
margin-bottom: 18px;
|
||||
}
|
||||
.search {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: end;
|
||||
gap: 16px;
|
||||
margin: 24px 0;
|
||||
}
|
||||
.search label {
|
||||
flex: 1 1 240px;
|
||||
min-width: 0;
|
||||
}
|
||||
.actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 12px;
|
||||
margin-top: 20px;
|
||||
}
|
||||
.list {
|
||||
display: grid;
|
||||
gap: 24px;
|
||||
margin-top: 24px;
|
||||
min-width: 0;
|
||||
}
|
||||
.record {
|
||||
border: 1px solid var(--line);
|
||||
border-radius: 12px;
|
||||
padding: clamp(16px, 3vw, 24px);
|
||||
min-width: 0;
|
||||
}
|
||||
.record code,
|
||||
.record h3,
|
||||
.record p {
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
.record h3 {
|
||||
font-size: 22px;
|
||||
}
|
||||
.reason {
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
.confirm {
|
||||
border-top: 1px solid var(--line);
|
||||
padding-top: 24px;
|
||||
margin-top: 24px;
|
||||
}
|
||||
.confirm label {
|
||||
margin-top: 20px;
|
||||
}
|
||||
.page {
|
||||
max-width: 900px;
|
||||
}
|
||||
.page p {
|
||||
line-height: 1.8;
|
||||
}
|
||||
44
app/ban/appeal/page.tsx
Normal file
44
app/ban/appeal/page.tsx
Normal file
@@ -0,0 +1,44 @@
|
||||
import Link from "next/link";
|
||||
import { Header, Footer } from "@/components/Shell";
|
||||
import { AccountAppeal } from "@/components/AccountAppeal";
|
||||
import { rawUser } from "@/lib/supabase";
|
||||
import { getI18n } from "@/lib/i18n";
|
||||
import styles from "./page.module.css";
|
||||
export const metadata = { title: "Account access & appeals" };
|
||||
export const dynamic = "force-dynamic";
|
||||
export default async function AppealPage() {
|
||||
const [account, { locale }] = await Promise.all([rawUser(), getI18n()]);
|
||||
const ru = locale === "ru";
|
||||
return (
|
||||
<>
|
||||
<Header />
|
||||
<main className={`section page-content ${styles.page}`}>
|
||||
<span className="eyebrow">MINEGEO</span>
|
||||
<h1>{ru ? "Доступ и апелляции." : "Account access & appeals."}</h1>
|
||||
{account ? (
|
||||
<AccountAppeal />
|
||||
) : (
|
||||
<>
|
||||
<p className="lead">
|
||||
{ru
|
||||
? "Войдите в заблокированный аккаунт, чтобы прочитать причину и подать апелляцию."
|
||||
: "Log in to the affected account to see the reason and submit a ban appeal."}
|
||||
</p>
|
||||
<Link
|
||||
className="button primary"
|
||||
href="/log-in?next=%2Fban%2Fappeal"
|
||||
>
|
||||
{ru ? "Войти" : "Log in"}
|
||||
</Link>
|
||||
<p>
|
||||
<Link href="/docs?page=account-bans">
|
||||
{ru ? "Как работают апелляции" : "How appeals work"}
|
||||
</Link>
|
||||
</p>
|
||||
</>
|
||||
)}
|
||||
</main>
|
||||
<Footer />
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user