From 404ca1cc5962bc65d3f1688fcc33b4239597c389 Mon Sep 17 00:00:00 2001 From: rngsurrounded Date: Mon, 3 Mar 2025 20:19:43 +0900 Subject: [PATCH] fix test --- .../components/SolutionHistorySheet/index.tsx | 10 +--------- .../TaskSolution/components/SolutionStatus/index.tsx | 1 - .../CompetitionSession/modules/TaskSolution/index.tsx | 3 --- 3 files changed, 1 insertion(+), 13 deletions(-) diff --git a/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionHistorySheet/index.tsx b/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionHistorySheet/index.tsx index 1abcabb..ed88c68 100644 --- a/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionHistorySheet/index.tsx +++ b/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionHistorySheet/index.tsx @@ -11,7 +11,6 @@ interface SolutionHistorySheetProps { solutions: Solution[]; maxPoints: number; onSolutionSelect: (solution: Solution) => void; - currentSolutionId?: string; } const SolutionHistorySheet: React.FC = ({ @@ -20,7 +19,6 @@ const SolutionHistorySheet: React.FC = ({ solutions, maxPoints, onSolutionSelect, - currentSolutionId }) => { return ( @@ -41,18 +39,12 @@ const SolutionHistorySheet: React.FC = ({ solutions.map((solution, index) => (
{ onSolutionSelect(solution); onOpenChange(false); }} > - {solution.id === currentSolutionId && ( -
- -
- )}
)) diff --git a/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionStatus/index.tsx b/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionStatus/index.tsx index 8596c97..b67c5ac 100644 --- a/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionStatus/index.tsx +++ b/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/components/SolutionStatus/index.tsx @@ -11,7 +11,6 @@ const SolutionStatus: React.FC = ({ solution, maxPoints }) => { const formattedDate = solution.timestamp ? format(parseISO(solution.timestamp), "d MMMM, HH:mm", { locale: ru }) : ''; - console.log(solution, "SOLUTION STATUS") return (
diff --git a/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/index.tsx b/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/index.tsx index 2d0df9e..9deb45a 100644 --- a/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/index.tsx +++ b/services/frontend/src/pages/CompetitionSession/modules/TaskSolution/index.tsx @@ -42,7 +42,6 @@ const TaskSolution: React.FC = ({ const solutionHistory = solutionsQuery.data || []; - // Set initial solution to the last one (most recent) when solutions are loaded useEffect(() => { if (solutionHistory.length > 0 && !displayedSolution) { const latestSolution = solutionHistory[solutionHistory.length - 1]; @@ -50,10 +49,8 @@ const TaskSolution: React.FC = ({ } }, [solutionHistory, displayedSolution]); - // When task changes, reset everything and load the latest solution for the new task useEffect(() => { if (prevTaskIdRef.current !== task.id) { - // Reset states for new task setDisplayedSolution(null); setSelectedSolutionUrl(null);