diff --git a/app/protected/help/page.tsx b/app/protected/help/page.tsx new file mode 100644 index 00000000..eda45c57 --- /dev/null +++ b/app/protected/help/page.tsx @@ -0,0 +1,356 @@ +'use client' + +import React, { useState } from 'react' +import { Input } from '@/components/ui/input' +import { Button } from '@/components/ui/button' +import { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card' +import { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from '@/components/ui/accordion' +import { + Search, + HelpCircle, + Mail, + MessageSquare, + BookOpen, + Settings, + Shield, + Users, + Trophy, + Calendar, + Code, + AlertCircle, + CheckCircle, + Clock, + ExternalLink +} from 'lucide-react' + +const quickActions = [ + { icon: Shield, title: 'Reset Password', description: 'Change your account password', href: '/protected/settings' }, + { icon: Users, title: 'Update Profile', description: 'Edit your profile information', href: '/protected/profile/view' }, + { icon: Mail, title: 'Contact Support', description: 'Get help from our team', action: 'contact' }, + { icon: AlertCircle, title: 'Report a Bug', description: 'Help us improve the platform', action: 'bug' }, +] + +const faqCategories = [ + { + title: 'Getting Started', + icon: BookOpen, + faqs: [ + { + question: 'How do I complete my profile?', + answer: 'Go to your profile page by clicking on your avatar in the sidebar, then click "Edit Profile". Fill in all required fields including your bio, skills, and education details.' + }, + { + question: 'How do I navigate the platform?', + answer: 'Use the sidebar on the left to access different sections. On mobile, tap the menu icon in the top-left corner. The dashboard gives you an overview of all your activities.' + }, + { + question: 'What are the main features available?', + answer: 'Codeunia offers courses, assignments, tests, hackathons, events, messaging, connections, study groups, mentorship, and career opportunities all in one platform.' + } + ] + }, + { + title: 'Courses & Learning', + icon: BookOpen, + faqs: [ + { + question: 'How do I enroll in a course?', + answer: 'Navigate to "My Courses" from the sidebar, browse available courses, and click "Enroll" on any course you\'re interested in. Some courses may have prerequisites.' + }, + { + question: 'Where can I find my assignments?', + answer: 'All your assignments are listed in the "Assignments" section. You can filter by course, due date, or status (pending, submitted, graded).' + }, + { + question: 'How do I submit an assignment?', + answer: 'Open the assignment, complete the required work, and click "Submit". You can attach files, add links, or write text responses depending on the assignment type.' + } + ] + }, + { + title: 'Tests & Assessments', + icon: Trophy, + faqs: [ + { + question: 'How do I take a test?', + answer: 'Go to "Test Dashboard" or "Browse Tests", select a test, and click "Start Test". Make sure you have a stable internet connection and enough time to complete it.' + }, + { + question: 'Can I retake a test?', + answer: 'It depends on the test settings. Some tests allow multiple attempts while others are one-time only. Check the test details before starting.' + }, + { + question: 'Where can I see my test results?', + answer: 'Your test results are available in "Grades & Progress" section. You can view detailed feedback, correct answers, and your performance analytics.' + } + ] + }, + { + title: 'Messages & Connections', + icon: MessageSquare, + faqs: [ + { + question: 'How do I send a message?', + answer: 'Go to the Messages section, click "New Message", search for the person you want to message, and start chatting. You can also message from their profile.' + }, + { + question: 'How do I add connections?', + answer: 'Visit the Connections page, use the search tab to find users, and click "Follow" on their profile. They can follow you back to create a mutual connection.' + }, + { + question: 'Can I create group chats?', + answer: 'Yes! In the Messages section, click "New Message" and select multiple recipients to create a group conversation.' + } + ] + }, + { + title: 'Events & Activities', + icon: Calendar, + faqs: [ + { + question: 'How do I join a hackathon?', + answer: 'Browse available hackathons in the "Hackathons" section, read the details, and click "Register". You can participate individually or as a team.' + }, + { + question: 'How do I register for events?', + answer: 'Go to "Events & Workshops", find an event you\'re interested in, and click "Register". You\'ll receive confirmation and reminders via email.' + }, + { + question: 'Can I create my own project?', + answer: 'Yes! Visit the "Projects" section and click "Create Project". Add details, invite collaborators, and showcase your work to the community.' + } + ] + }, + { + title: 'Technical Issues', + icon: Code, + faqs: [ + { + question: 'I can\'t log in to my account', + answer: 'Try resetting your password using the "Forgot Password" link. If that doesn\'t work, clear your browser cache or try a different browser. Contact support if the issue persists.' + }, + { + question: 'The page is loading slowly', + answer: 'Check your internet connection. Try refreshing the page or clearing your browser cache. If the issue continues, it might be temporary server maintenance.' + }, + { + question: 'I\'m not receiving email notifications', + answer: 'Check your spam folder. Verify your email address in Settings. Make sure notifications are enabled in your account preferences.' + } + ] + }, + { + title: 'Account & Settings', + icon: Settings, + faqs: [ + { + question: 'How do I change my password?', + answer: 'Go to Settings, click on "Security", and select "Change Password". Enter your current password and your new password twice to confirm.' + }, + { + question: 'How do I manage notifications?', + answer: 'Visit Settings > Notifications to customize which notifications you receive via email, push, or in-app alerts.' + }, + { + question: 'Can I delete my account?', + answer: 'Yes, but this action is permanent. Go to Settings > Account > Delete Account. You\'ll need to confirm this action and all your data will be removed.' + } + ] + } +] + +export default function HelpPage() { + const [searchQuery, setSearchQuery] = useState('') + const [filteredFaqs, setFilteredFaqs] = useState(faqCategories) + + const handleSearch = (query: string) => { + setSearchQuery(query) + + if (!query.trim()) { + setFilteredFaqs(faqCategories) + return + } + + const filtered = faqCategories.map(category => ({ + ...category, + faqs: category.faqs.filter(faq => + faq.question.toLowerCase().includes(query.toLowerCase()) || + faq.answer.toLowerCase().includes(query.toLowerCase()) + ) + })).filter(category => category.faqs.length > 0) + + setFilteredFaqs(filtered) + } + + return ( +
+ Find answers to common questions or get in touch with our support team +
+No results found
+Try different keywords or contact support
+Email Support
+support@codeunia.com
+Response time: 24-48 hours
+Support Hours
+Monday - Friday: 9:00 AM - 6:00 PM IST
+Saturday: 10:00 AM - 4:00 PM IST
+All Systems Operational
+Last checked: Just now
+