diff --git a/src/app/(app)/playground/@problem/layout.tsx b/src/app/(app)/playground/@problem/layout.tsx index 23a2af6..2d93f1e 100644 --- a/src/app/(app)/playground/@problem/layout.tsx +++ b/src/app/(app)/playground/@problem/layout.tsx @@ -1,3 +1,7 @@ +"use client"; + +import { Skeleton } from "@/components/ui/skeleton"; +import { useTabsStore } from "@/store/useTabsStore"; import { ScrollArea, ScrollBar } from "@/components/ui/scroll-area"; import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs"; import { CircleCheckBigIcon, FileTextIcon, FlaskConicalIcon } from "lucide-react"; @@ -13,8 +17,22 @@ export default function ProblemLayout({ solution, submission, }: ProblemLayoutProps) { + const { hydrated, problemTab, setProblemTab } = useTabsStore(); + + if (!hydrated) return ( +