gitscope
https://dev.kronoz.win/r/marzneshin.git
dashboard/src/routes/_dashboard/nodes.tsx · v0.3.0-alpha
Source
1 b15ff05 Mrdn 2y ago import { Alert, AlertDescription, AlertTitle, Card, CardContent, CardFooter, CardHeader, CardTitle } from '@marzneshin/components';
2 b15ff05 Mrdn 2y ago import { NodesTable } from '@marzneshin/features/nodes';
3 b15ff05 Mrdn 2y ago import { Link, createFileRoute } from '@tanstack/react-router'
4 b15ff05 Mrdn 2y ago import { Info } from 'lucide-react';
5 b15ff05 Mrdn 2y ago import { FC } from 'react';
6 b15ff05 Mrdn 2y ago import { useTranslation } from 'react-i18next';
7 b15ff05 Mrdn 2y ago
8 b15ff05 Mrdn 2y ago export const NodesPage: FC = () => {
9 b15ff05 Mrdn 2y ago const { t } = useTranslation();
10 b15ff05 Mrdn 2y ago return (
11 b15ff05 Mrdn 2y ago <Card className="m-3">
12 b15ff05 Mrdn 2y ago <CardHeader>
13 b15ff05 Mrdn 2y ago <CardTitle>
14 b15ff05 Mrdn 2y ago {t('nodes')}
15 b15ff05 Mrdn 2y ago </CardTitle>
16 b15ff05 Mrdn 2y ago </CardHeader>
17 b15ff05 Mrdn 2y ago <CardContent>
18 b15ff05 Mrdn 2y ago <NodesTable />
19 b15ff05 Mrdn 2y ago </CardContent>
20 b15ff05 Mrdn 2y ago <CardFooter>
21 b15ff05 Mrdn 2y ago <Alert>
22 b15ff05 Mrdn 2y ago <Info className="mr-2" />
23 b15ff05 Mrdn 2y ago <AlertTitle className="font-semibold text-primary">{t('page.nodes.certificate-alert.title')}</AlertTitle>
24 b15ff05 Mrdn 2y ago <AlertDescription>
25 b15ff05 Mrdn 2y ago {t('page.nodes.certificate-alert.desc')}
26 b15ff05 Mrdn 2y ago <Link className="m-1 font-semibold text-secondary-foreground" to="/settings">{t('page.nodes.certificate-alert.click')}</Link>
27 b15ff05 Mrdn 2y ago </AlertDescription>
28 b15ff05 Mrdn 2y ago </Alert>
29 b15ff05 Mrdn 2y ago </CardFooter>
30 b15ff05 Mrdn 2y ago </Card >)
31 b15ff05 Mrdn 2y ago };
32 1eb203e Mrdn 2y ago
33 1eb203e Mrdn 2y ago export const Route = createFileRoute('/_dashboard/nodes')({
34 b15ff05 Mrdn 2y ago component: () => <NodesPage />
35 b15ff05 Mrdn 2y ago })