import React from 'react'; import { CheckCircle } from 'lucide-react'; export interface Step { id: number; label: string; description?: string; component: React.ReactNode; } interface WorkflowStepperProps { steps: Step[]; currentStep: number; } export function WorkflowStepper({ steps, currentStep }: WorkflowStepperProps) { const activeStepContent = steps.find((step) => step.id === currentStep)?.component; return (
{steps.map((step, index) => { const isCompleted = step.id < currentStep; const isActive = step.id === currentStep; return (
{isCompleted ? : {step.id}}

{step.label}

{step.description && (

{step.description}

)}
{index < steps.length - 1 && (
)} ); })}
{activeStepContent}
); }