import { useState } from 'react'; import { Button } from '@/components/ui/button'; import { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card'; import { Textarea } from '@/components/ui/textarea'; import { ArrowLeft, Plus, Sparkles } from 'lucide-react'; import { useProjectsManager } from '@/hooks/useProjectsManager'; import { useNavigate } from 'react-router-dom'; interface ProjectStepProps { onNext: () => void; onPrevious: () => void; onComplete: () => void; onProjectCreated?: (projectId: string) => void; } export function ProjectStep({ onPrevious, onComplete, onProjectCreated }: ProjectStepProps) { const [prompt, setPrompt] = useState(''); const [isCreating, setIsCreating] = useState(false); const projectsManager = useProjectsManager(); const navigate = useNavigate(); const handleCreateProject = async () => { if (!prompt.trim()) return; setIsCreating(true); try { const project = await projectsManager.createProject(prompt.trim()); onProjectCreated?.(project.id); onComplete(); navigate(`/project/${project.id}`); } catch (error) { console.error('Failed to create project:', error); } finally { setIsCreating(false); } }; return (

Create Your First Project

Our AI will help you create it step by step.

Project Description
Be as detailed as possible about what you want to build