diff --git a/src/app/problems/[problemNum]/page.tsx b/src/app/problems/[problemNum]/page.tsx index acb2d30..9eeee8b 100644 --- a/src/app/problems/[problemNum]/page.tsx +++ b/src/app/problems/[problemNum]/page.tsx @@ -22,6 +22,7 @@ import { columns } from "./components/data-table/ranklistColumns"; import Loading from "./loading"; import Link from "next/link"; import { uhuntViewProblemUrl } from "@/utils/constants"; +import { Problem, Submission } from "@/types"; type problemPageProps = { params: z.infer; @@ -101,16 +102,15 @@ const ProblemPage = ({ params }: problemPageProps) => { // console.log(problemNumData); } - const processedProblemVerdictData = processProblemNumBarChartData(problemNumData); - + const processedProblemVerdictData = processProblemNumBarChartData( problemNumData as Problem); return (
- {params.problemNum}: {problemNumData.title} + {params.problemNum}: {( problemNumData as Problem ).title}
{/* Submission verdicts bar chart */} @@ -151,7 +151,7 @@ const ProblemPage = ({ params }: problemPageProps) => {

Ranklist (Top 10)

@@ -159,7 +159,7 @@ const ProblemPage = ({ params }: problemPageProps) => {

Submissions

diff --git a/src/app/problems/page.tsx b/src/app/problems/page.tsx index a1d05d6..30764b2 100644 --- a/src/app/problems/page.tsx +++ b/src/app/problems/page.tsx @@ -4,6 +4,7 @@ import { DataTable } from "@/components/ui/data-table"; import DataTableLoading from "@/components/ui/data-table/loading"; import { columns } from "@/app/problems/components/data-table/columns"; import { useFetchProblems } from "@/hooks"; +import { Problem } from "@/types"; const ProblemsPage = () => { const { data, isLoading, isError } = useFetchProblems(); @@ -24,7 +25,7 @@ const ProblemsPage = () => { return (

All Problems

- +
); };