feat: Mantine design system with dark mode
This commit is contained in:
parent
6e12720ad6
commit
38d4899b07
18 changed files with 1170 additions and 322 deletions
|
|
@ -1,3 +1,5 @@
|
|||
import { Alert, Stack, Title } from "@mantine/core";
|
||||
import { IconAlertCircle } from "@tabler/icons-react";
|
||||
import AdminTab from "../components/AdminTab";
|
||||
import ApprovalsTab from "../components/ApprovalsTab";
|
||||
import AccessQueue from "../components/AccessQueue";
|
||||
|
|
@ -8,25 +10,37 @@ export default function AdminPage() {
|
|||
if (!me) {
|
||||
return (
|
||||
<div>
|
||||
<h2>Verwaltung</h2>
|
||||
<p>Bitte melden Sie sich an, um die Verwaltung zu nutzen.</p>
|
||||
<Title order={2} mb="md">
|
||||
Verwaltung
|
||||
</Title>
|
||||
<Alert color="blue">
|
||||
Bitte melden Sie sich an, um die Verwaltung zu nutzen.
|
||||
</Alert>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
if (me.role !== "admin") {
|
||||
return (
|
||||
<div>
|
||||
<h2>Verwaltung</h2>
|
||||
<p>Nur für Administratoren. Ihr Konto hat die Rolle „{me.role}“.</p>
|
||||
<Title order={2} mb="md">
|
||||
Verwaltung
|
||||
</Title>
|
||||
<Alert color="red" icon={<IconAlertCircle size={18} />}>
|
||||
Nur für Administratoren. Ihr Konto hat die Rolle „{me.role}“.
|
||||
</Alert>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
return (
|
||||
<div>
|
||||
<h2>Verwaltung</h2>
|
||||
<AccessQueue />
|
||||
<ApprovalsTab />
|
||||
<AdminTab />
|
||||
<Title order={2} mb="md">
|
||||
Verwaltung
|
||||
</Title>
|
||||
<Stack gap="xl">
|
||||
<AccessQueue />
|
||||
<ApprovalsTab />
|
||||
<AdminTab />
|
||||
</Stack>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue