mirror of
https://github.com/massbug/judge4c.git
synced 2025-05-17 23:12:23 +00:00
style(problem): adjust problem layout styles
This commit is contained in:
parent
569beb0b36
commit
30ee16fbf0
@ -9,8 +9,8 @@ interface CodeLayoutProps {
|
|||||||
|
|
||||||
export default function CodeLayout({ children }: CodeLayoutProps) {
|
export default function CodeLayout({ children }: CodeLayoutProps) {
|
||||||
return (
|
return (
|
||||||
<div className="flex flex-col h-full">
|
<div className="flex flex-col h-full border border-t-0 border-muted rounded-b-3xl bg-background">
|
||||||
<WorkspaceEditorHeader className="border-b border-x border-muted bg-background" />
|
<WorkspaceEditorHeader />
|
||||||
<Suspense fallback={<Loading />}>
|
<Suspense fallback={<Loading />}>
|
||||||
{children}
|
{children}
|
||||||
</Suspense>
|
</Suspense>
|
||||||
|
@ -2,7 +2,7 @@ import { ProblemEditor } from "@/components/problem-editor";
|
|||||||
|
|
||||||
export default function CodePage() {
|
export default function CodePage() {
|
||||||
return (
|
return (
|
||||||
<div className="relative flex-1 border-x border-muted">
|
<div className="relative flex-1">
|
||||||
<div className="absolute w-full h-full">
|
<div className="absolute w-full h-full">
|
||||||
<ProblemEditor />
|
<ProblemEditor />
|
||||||
</div>
|
</div>
|
||||||
|
@ -7,7 +7,7 @@ interface DescriptionLayoutProps {
|
|||||||
|
|
||||||
export default function DescriptionLayout({ children }: DescriptionLayoutProps) {
|
export default function DescriptionLayout({ children }: DescriptionLayoutProps) {
|
||||||
return (
|
return (
|
||||||
<div className="h-full flex flex-col">
|
<div className="h-full flex flex-col border border-t-0 border-muted rounded-b-3xl bg-background">
|
||||||
<Suspense fallback={<Loading />}>
|
<Suspense fallback={<Loading />}>
|
||||||
{children}
|
{children}
|
||||||
</Suspense>
|
</Suspense>
|
||||||
|
@ -29,7 +29,7 @@ export default async function DescriptionPage({ params }: DescriptionPageProps)
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className="relative flex-1 border-x border-muted">
|
<div className="relative flex-1">
|
||||||
<div className="absolute h-full w-full">
|
<div className="absolute h-full w-full">
|
||||||
<ScrollArea className="h-full [&>[data-radix-scroll-area-viewport]>div:min-w-0 [&>[data-radix-scroll-area-viewport]>div]:!block bg-background">
|
<ScrollArea className="h-full [&>[data-radix-scroll-area-viewport]>div:min-w-0 [&>[data-radix-scroll-area-viewport]>div]:!block bg-background">
|
||||||
<MdxPreview source={problem.description} className="p-4 md:p-6" />
|
<MdxPreview source={problem.description} className="p-4 md:p-6" />
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
import { Suspense } from "react";
|
import { Suspense } from "react";
|
||||||
|
import { getUserLocale } from "@/i18n/locale";
|
||||||
import { Loading } from "@/components/loading";
|
import { Loading } from "@/components/loading";
|
||||||
|
import DetailsPage from "@/app/(app)/problems/[id]/@Details/page";
|
||||||
|
|
||||||
interface DetailsLayoutProps {
|
export default async function DetailsLayout() {
|
||||||
children: React.ReactNode;
|
const locale = await getUserLocale();
|
||||||
}
|
|
||||||
|
|
||||||
export default async function DetailsLayout({ children }: DetailsLayoutProps) {
|
|
||||||
return (
|
return (
|
||||||
<div className="flex flex-col h-full border border-t-0 border-muted rounded-b-3xl bg-background">
|
<div className="flex flex-col h-full border border-t-0 border-muted rounded-b-3xl bg-background">
|
||||||
<Suspense fallback={<Loading />}>
|
<Suspense fallback={<Loading />}>
|
||||||
{children}
|
<DetailsPage locale={locale} />;
|
||||||
</Suspense>
|
</Suspense>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
@ -7,7 +7,7 @@ interface SolutionsLayoutProps {
|
|||||||
|
|
||||||
export default async function SolutionsLayout({ children }: SolutionsLayoutProps) {
|
export default async function SolutionsLayout({ children }: SolutionsLayoutProps) {
|
||||||
return (
|
return (
|
||||||
<div className="flex flex-col h-full">
|
<div className="flex flex-col h-full border border-t-0 border-muted rounded-b-3xl bg-background">
|
||||||
<Suspense fallback={<Loading />}>
|
<Suspense fallback={<Loading />}>
|
||||||
{children}
|
{children}
|
||||||
</Suspense>
|
</Suspense>
|
||||||
|
@ -29,7 +29,7 @@ export default async function SolutionsPage({ params }: SolutionsPageProps) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className="relative flex-1 border-x border-muted">
|
<div className="relative flex-1">
|
||||||
<div className="absolute h-full w-full">
|
<div className="absolute h-full w-full">
|
||||||
<ScrollArea className="h-full [&>[data-radix-scroll-area-viewport]>div:min-w-0 [&>[data-radix-scroll-area-viewport]>div]:!block bg-background">
|
<ScrollArea className="h-full [&>[data-radix-scroll-area-viewport]>div:min-w-0 [&>[data-radix-scroll-area-viewport]>div]:!block bg-background">
|
||||||
<MdxPreview source={problem.solution} className="p-4 md:p-6" />
|
<MdxPreview source={problem.solution} className="p-4 md:p-6" />
|
||||||
|
Loading…
Reference in New Issue
Block a user