website refactor

This commit is contained in:
2026-01-16 01:00:03 +01:00
parent ce7be39155
commit a98e3e3166
286 changed files with 5522 additions and 5261 deletions

View File

@@ -1,5 +1,5 @@
import { notFound } from 'next/navigation';
import { ProfileLeaguesPageQuery } from '@/lib/page-queries/page-queries/ProfileLeaguesPageQuery';
import { ProfileLeaguesPageQuery } from '@/lib/page-queries/ProfileLeaguesPageQuery';
import { ProfileLeaguesTemplate } from '@/templates/ProfileLeaguesTemplate';
export default async function ProfileLeaguesPage() {

View File

@@ -1,11 +1,13 @@
import Link from 'next/link';
import { Button } from '@/ui/Button';
import { Card } from '@/ui/Card';
import { Container } from '@/ui/Container';
import { Heading } from '@/ui/Heading';
import { Grid } from '@/ui/Grid';
import { routes } from '@/lib/routing/RouteConfig';
import { LiveryCard } from '@/ui/LiveryCard';
import { Stack } from '@/ui/Stack';
import { Box } from '@/ui/Box';
import { Text } from '@/ui/Text';
export default async function ProfileLiveriesPage() {
const mockLiveries = [
@@ -14,7 +16,7 @@ export default async function ProfileLiveriesPage() {
carId: 'gt3-r',
carName: 'Porsche 911 GT3 R (992)',
thumbnailUrl: '',
uploadedAt: new Date(),
uploadedAt: new globalThis.Date(),
isValidated: true,
},
{
@@ -22,22 +24,22 @@ export default async function ProfileLiveriesPage() {
carId: 'f3',
carName: 'Dallara F3',
thumbnailUrl: '',
uploadedAt: new Date(),
uploadedAt: new globalThis.Date(),
isValidated: false,
}
];
return (
<Container size="lg" py={8}>
<div className="flex items-center justify-between mb-8">
<div>
<Stack direction="row" align="center" justify="between" mb={8}>
<Box>
<Heading level={1}>My Liveries</Heading>
<p className="text-gray-400 mt-1">Manage your custom car liveries</p>
</div>
<Text color="text-gray-400" mt={1} block>Manage your custom car liveries</Text>
</Box>
<Link href={routes.protected.profileLiveryUpload}>
<Button variant="primary">Upload livery</Button>
</Link>
</div>
</Stack>
<Grid cols={3} gap={6}>
{mockLiveries.map((livery) => (
@@ -45,11 +47,11 @@ export default async function ProfileLiveriesPage() {
))}
</Grid>
<div className="mt-12">
<Box mt={12}>
<Link href={routes.protected.profile}>
<Button variant="secondary">Back to profile</Button>
</Link>
</div>
</Box>
</Container>
);
}

View File

@@ -3,6 +3,7 @@ import { Button } from '@/ui/Button';
import { Card } from '@/ui/Card';
import { Container } from '@/ui/Container';
import { Heading } from '@/ui/Heading';
import { Text } from '@/ui/Text';
import { routes } from '@/lib/routing/RouteConfig';
export default async function ProfileLiveryUploadPage() {
@@ -10,7 +11,7 @@ export default async function ProfileLiveryUploadPage() {
<Container size="md">
<Heading level={1}>Upload livery</Heading>
<Card>
<p>Livery upload is currently unavailable.</p>
<Text block mb={4}>Livery upload is currently unavailable.</Text>
<Link href={routes.protected.profileLiveries}>
<Button variant="secondary">Back to liveries</Button>
</Link>

View File

@@ -1,4 +1,4 @@
import { ProfilePageQuery } from '@/lib/page-queries/page-queries/ProfilePageQuery';
import { ProfilePageQuery } from '@/lib/page-queries/ProfilePageQuery';
import { notFound } from 'next/navigation';
import { updateProfileAction } from './actions';
import { ProfilePageClient } from './ProfilePageClient';

View File

@@ -3,6 +3,7 @@ import { Button } from '@/ui/Button';
import { Card } from '@/ui/Card';
import { Container } from '@/ui/Container';
import { Heading } from '@/ui/Heading';
import { Text } from '@/ui/Text';
import { routes } from '@/lib/routing/RouteConfig';
export default async function ProfileSettingsPage() {
@@ -10,7 +11,7 @@ export default async function ProfileSettingsPage() {
<Container size="md">
<Heading level={1}>Settings</Heading>
<Card>
<p>Settings are currently unavailable.</p>
<Text block mb={4}>Settings are currently unavailable.</Text>
<Link href={routes.protected.profile}>
<Button variant="secondary">Back to profile</Button>
</Link>

View File

@@ -1,5 +1,5 @@
import { notFound } from 'next/navigation';
import { SponsorshipRequestsPageQuery } from '@/lib/page-queries/page-queries/SponsorshipRequestsPageQuery';
import { SponsorshipRequestsPageQuery } from '@/lib/page-queries/SponsorshipRequestsPageQuery';
import { SponsorshipRequestsClient } from './SponsorshipRequestsClient';
import { acceptSponsorshipRequest, rejectSponsorshipRequest } from './actions';