UNPKG

analytica-frontend-lib

Version:

Repositório público dos componentes utilizados nas plataformas da Analytica Ensino

157 lines 4.05 kB
/** * Activity Details Types * Types and helper functions for activity details components */ import { z } from 'zod'; /** * Student activity status enum */ export declare const STUDENT_ACTIVITY_STATUS: { readonly CONCLUIDO: "CONCLUIDO"; readonly AGUARDANDO_CORRECAO: "AGUARDANDO_CORRECAO"; readonly AGUARDANDO_RESPOSTA: "AGUARDANDO_RESPOSTA"; readonly NAO_ENTREGUE: "NAO_ENTREGUE"; /** Physical test (presencial): student hasn't submitted the answer sheet yet */ readonly AWAITING_ANSWER_SHEET: "AGUARDANDO_GABARITO"; /** Physical test (presencial): answer sheet has been received and processed */ readonly ANSWER_SHEET_RECEIVED: "GABARITO_RECEBIDO"; }; export type StudentActivityStatus = (typeof STUDENT_ACTIVITY_STATUS)[keyof typeof STUDENT_ACTIVITY_STATUS]; /** * Zod schema for student activity status */ export declare const studentActivityStatusSchema: z.ZodEnum<{ CONCLUIDO: "CONCLUIDO"; AGUARDANDO_CORRECAO: "AGUARDANDO_CORRECAO"; AGUARDANDO_RESPOSTA: "AGUARDANDO_RESPOSTA"; NAO_ENTREGUE: "NAO_ENTREGUE"; AGUARDANDO_GABARITO: "AGUARDANDO_GABARITO"; GABARITO_RECEBIDO: "GABARITO_RECEBIDO"; }>; /** * Student data interface */ export interface ActivityStudentData { studentId: string; studentName: string; answeredAt: string | null; timeSpent: number; score: number | null; status: StudentActivityStatus; } /** * Pagination interface */ export interface Pagination { total: number; page: number; limit: number; totalPages: number; hasNext?: boolean; hasPrev?: boolean; } /** * General statistics interface */ export interface GeneralStats { averageScore: number; completionPercentage: number; } /** * Question statistics interface */ export interface QuestionStats { mostCorrect: number[]; mostIncorrect: number[]; notAnswered: number[]; } /** * Activity metadata interface */ export interface ActivityMetadata { id: string; title: string; type?: string; subtype?: string; isDigital?: boolean | null; startDate: string | null; finalDate: string | null; schoolName: string; year: string; subjectName: string; className: string; } /** * Activity details data interface */ export interface ActivityDetailsData { activity?: ActivityMetadata; students: ActivityStudentData[]; pagination: Pagination; generalStats: GeneralStats; questionStats: QuestionStats; } /** * Activity details query params interface */ export interface ActivityDetailsQueryParams { page?: number; limit?: number; sortBy?: 'name' | 'score' | 'answeredAt'; sortOrder?: 'asc' | 'desc'; status?: StudentActivityStatus; } /** * Activity student table item interface */ export interface ActivityStudentTableItem extends Record<string, unknown> { id: string; studentId: string; studentName: string; status: StudentActivityStatus; answeredAt: string | null; timeSpent: number; score: number | null; } /** * Status badge configuration interface */ export interface StatusBadgeConfig { label: string; bgColor: string; textColor: string; } /** * Activity availability status enum * Used to determine if an activity is available based on start/end dates */ export declare const ACTIVITY_AVAILABILITY: { readonly DISPONIVEL: "DISPONIVEL"; readonly NAO_INICIADA: "NAO_INICIADA"; readonly EXPIRADA: "EXPIRADA"; }; export type ActivityAvailability = (typeof ACTIVITY_AVAILABILITY)[keyof typeof ACTIVITY_AVAILABILITY]; /** * Quiz API response */ export interface QuizResponse { message: string; data: ActivityMetadata; } /** * Activity details API response (without activity) */ export interface ActivityDetailsApiResponse { message: string; data: Omit<ActivityDetailsData, 'activity'>; } /** * Presigned URL response */ export interface PresignedUrlResponse { data: { signedUrl: string; publicUrl: string; }; } //# sourceMappingURL=activityDetails.d.ts.map