"use client"; import { LoadingState, type LoadingStage } from "@/components/LoadingState"; import type { HomeworkProgress } from "@/lib/client-api"; import type { HomeworkMode } from "@/lib/schemas"; /** * Loading state while the assignment is read and answered — the same screen * as the deck wizard (components/LoadingState), with the homework wording. */ export function HomeworkLoading({ progress, mode, onCancel, }: { progress: HomeworkProgress; mode: HomeworkMode; onCancel: () => void; }) { const generationKey = mode === "make" ? "homework.loading.writing" : mode === "check" ? "homework.loading.checking" : "homework.loading.planning"; const stages: LoadingStage[] = [ { id: "vision", labelKey: "homework.loading.reading", messageKeys: ["homework.loading.reading", "homework.loading.vision2"], }, { id: "generation", labelKey: generationKey, messageKeys: [generationKey, "homework.loading.gen2", "homework.loading.gen3"], }, ]; return ( ); }