Skip to content

Commit e83e6a3

Browse files
committed
feat: adjust the layout of the demo
1 parent 5db83f5 commit e83e6a3

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

playground/src/app/(demo)/layout.tsx

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import process from 'node:process';
44

55
import Link from 'next/link';
66
import React from 'react';
7+
import { ScrollArea } from 'soybean-react-ui';
78

89
import DemoTabs from './modules/DemoTabs';
910
import DemoTitle from './modules/DemoTitle';
@@ -42,13 +43,17 @@ function DemoLayout({ children }: { children: React.ReactNode }) {
4243
<>
4344
<DemoTabs items={componentTabs} />
4445

45-
<div className="mb-8 border border-gray-200 rounded-xl bg-white p-6 shadow-lg transition-all dark:border-neutral-700 dark:bg-neutral-800 hover:shadow-xl">
46-
<h3 className="mb-4 border-b border-gray-200 pb-2 text-xl text-gray-800 font-bold dark:border-neutral-700 dark:text-gray-100">
47-
Demo <DemoTitle />
48-
</h3>
49-
50-
<div className="p-[18px]"> {children}</div>
51-
</div>
46+
<ScrollArea className="h-full">
47+
<div className="p-[18px]">
48+
<div className="mb-8 border border-gray-200 rounded-xl bg-white p-6 shadow-lg transition-all dark:border-neutral-700 dark:bg-neutral-800 hover:shadow-xl">
49+
<h3 className="mb-4 border-b border-gray-200 pb-2 text-xl text-gray-800 font-bold dark:border-neutral-700 dark:text-gray-100">
50+
Demo <DemoTitle />
51+
</h3>
52+
53+
{children}
54+
</div>
55+
</div>
56+
</ScrollArea>
5257
</>
5358
);
5459
}

0 commit comments

Comments
 (0)