website refactor
This commit is contained in:
29
apps/website/client-wrapper/NotFoundPageClient.tsx
Normal file
29
apps/website/client-wrapper/NotFoundPageClient.tsx
Normal file
@@ -0,0 +1,29 @@
|
||||
'use client';
|
||||
|
||||
import React from 'react';
|
||||
import { useRouter } from 'next/navigation';
|
||||
import { routes } from '@/lib/routing/RouteConfig';
|
||||
import { NotFoundTemplate, type NotFoundViewData } from '@/templates/NotFoundTemplate';
|
||||
|
||||
/**
|
||||
* NotFoundPageClient
|
||||
*
|
||||
* Client-side entry point for the 404 page.
|
||||
* Manages navigation logic and wires it to the template.
|
||||
*/
|
||||
export function NotFoundPageClient() {
|
||||
const router = useRouter();
|
||||
|
||||
const handleHomeClick = () => {
|
||||
router.push(routes.public.home);
|
||||
};
|
||||
|
||||
const viewData: NotFoundViewData = {
|
||||
errorCode: 'Error 404',
|
||||
title: 'OFF TRACK',
|
||||
message: 'The requested sector does not exist. You have been returned to the pits.',
|
||||
actionLabel: 'Return to Pits'
|
||||
};
|
||||
|
||||
return <NotFoundTemplate viewData={viewData} onHomeClick={handleHomeClick} />;
|
||||
}
|
||||
Reference in New Issue
Block a user