feat(frontend): Complete authentication and dashboard pages with task management

This commit is contained in:
Erik Silva
2025-12-01 01:56:58 -03:00
parent 07fc4875c9
commit a59a9a9071
6 changed files with 658 additions and 59 deletions

View File

@@ -0,0 +1,22 @@
'use client';
import { useEffect } from 'react';
import { useRouter } from 'next/navigation';
import { useAuth } from '@/lib/stores';
export default function AuthLayout({
children,
}: {
children: React.ReactNode;
}) {
const router = useRouter();
const { user } = useAuth();
useEffect(() => {
if (user) {
router.push('/dashboard/tasks');
}
}, [user, router]);
return <>{children}</>;
}