import React from 'react'; import { Box, Card, CardContent, Typography, Button, LinearProgress, Stack } from '@mui/material'; import { Add as AddIcon, Visibility as VisibilityIcon, Download as DownloadIcon, ContactMail as ContactMailIcon, Edit as EditIcon, TipsAndUpdates as TipsIcon, } from '@mui/icons-material'; import { useAuth } from 'hooks/AuthContext'; import { LoginRequired } from 'components/ui/LoginRequired'; import { BackstoryElementProps } from 'components/BackstoryTab'; import { useNavigate } from 'react-router-dom'; import { ComingSoon } from 'components/ui/ComingSoon'; import { useAppState } from 'hooks/GlobalContext'; interface CandidateDashboardProps extends BackstoryElementProps { }; const CandidateDashboard = (props: CandidateDashboardProps) => { const { setSnack } = useAppState(); const navigate = useNavigate(); const { user } = useAuth(); const profileCompletion = 75; if (!user) { return ; } if (user?.userType !== 'candidate') { setSnack(`The page you were on is only available for candidates (you are a ${user.userType}`, 'warning'); navigate('/'); return (<>); } return (<> {/* Main Content */} {/* Welcome Section */} Welcome back, {user.firstName}! Your profile is {profileCompletion}% complete {/* Cards Grid */} {/* Top Row */} {/* Resume Builder Card */} Resume Builder 3 custom resumes Last created: May 15, 2025 {/* Recent Activity Card */} Recent Activity 5 profile views 2 resume downloads 1 direct contact {/* Bottom Row */} {/* Complete Your Backstory Card */} Complete Your Backstory • Add projects • Detail skills • Work history {/* Improvement Suggestions Card */} Improvement Suggestions • Add certifications • Enhance your project details ); }; export { CandidateDashboard };