import type { HomeworkAssignmentQuestionAnalytics } from "@/modules/homework/types" import { Card, CardContent, CardHeader, CardTitle } from "@/shared/components/ui/card" import { ScrollArea } from "@/shared/components/ui/scroll-area" import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from "@/shared/components/ui/table" export function HomeworkAssignmentQuestionErrorDetailsCard({ questions, gradedSampleCount, }: { questions: HomeworkAssignmentQuestionAnalytics[] gradedSampleCount: number }) { return ( Question Error Details {questions.length === 0 || gradedSampleCount === 0 ? (
No data available.
) : ( Question Error Count Error Rate {questions.map((q, index) => (
Q{index + 1}
{q.errorCount} {(q.errorRate * 100).toFixed(1)}%
))}
)}
) }