diff --git a/client/pages/Onboarding.tsx b/client/pages/Onboarding.tsx new file mode 100644 index 00000000..ee670365 --- /dev/null +++ b/client/pages/Onboarding.tsx @@ -0,0 +1,120 @@ +import { useState } from "react"; +import Layout from "@/components/Layout"; +import UserTypeSelection from "@/components/onboarding/UserTypeSelection"; +import PersonalInfo from "@/components/onboarding/PersonalInfo"; +import Experience from "@/components/onboarding/Experience"; +import Interests from "@/components/onboarding/Interests"; +import Welcome from "@/components/onboarding/Welcome"; + +export type UserType = 'game-developer' | 'client' | 'member' | 'customer'; + +export interface OnboardingData { + userType: UserType | null; + personalInfo: { + firstName: string; + lastName: string; + email: string; + company?: string; + }; + experience: { + level: string; + skills: string[]; + previousProjects?: string; + }; + interests: { + primaryGoals: string[]; + preferredServices: string[]; + }; +} + +const initialData: OnboardingData = { + userType: null, + personalInfo: { + firstName: '', + lastName: '', + email: '', + company: '', + }, + experience: { + level: '', + skills: [], + previousProjects: '', + }, + interests: { + primaryGoals: [], + preferredServices: [], + }, +}; + +export default function Onboarding() { + const [currentStep, setCurrentStep] = useState(0); + const [data, setData] = useState(initialData); + + const steps = [ + { title: "Choose Your Path", component: UserTypeSelection }, + { title: "Personal Information", component: PersonalInfo }, + { title: "Experience Level", component: Experience }, + { title: "Interests & Goals", component: Interests }, + { title: "Welcome to AeThex", component: Welcome }, + ]; + + const updateData = (newData: Partial) => { + setData(prev => ({ ...prev, ...newData })); + }; + + const nextStep = () => { + if (currentStep < steps.length - 1) { + setCurrentStep(prev => prev + 1); + } + }; + + const prevStep = () => { + if (currentStep > 0) { + setCurrentStep(prev => prev - 1); + } + }; + + const CurrentStepComponent = steps[currentStep].component; + + return ( + +
+
+ {/* Progress Bar */} +
+
+

Join AeThex

+ + Step {currentStep + 1} of {steps.length} + +
+
+
+
+
+ + {/* Step Content */} +
+
+

+ {steps[currentStep].title} +

+
+ + +
+
+
+ + ); +}