import { RiCheckLine } from "@remixicon/react"; import { cn } from "@/shared/utils/ui"; type Step = "upload" | "review" | "done"; const STEPS: { key: Step; label: string }[] = [ { key: "upload", label: "Upload" }, { key: "review", label: "Revisar" }, { key: "done", label: "ConcluĂ­do" }, ]; const STEP_ORDER: Step[] = ["upload", "review", "done"]; interface ImportStepsProps { current: Step; } export function ImportSteps({ current }: ImportStepsProps) { const currentIndex = STEP_ORDER.indexOf(current); return (
{STEPS.map((step, index) => { const stepIndex = STEP_ORDER.indexOf(step.key); const isCompleted = stepIndex < currentIndex; const isActive = stepIndex === currentIndex; return (
{isCompleted ? ( ) : ( {index + 1} )}
{step.label}
{index < STEPS.length - 1 && (
)}
); })}
); }