-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9264396
commit fce57eb
Showing
5 changed files
with
93 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,38 @@ | ||
'use client'; | ||
|
||
import dynamic from 'next/dynamic'; | ||
import GridLayout from "react-grid-layout"; | ||
import 'react-grid-layout/css/styles.css'; | ||
|
||
const EditorView = dynamic(() => import('./editor'), { | ||
ssr: false, | ||
}); | ||
|
||
|
||
// layout is an array of objects, see the demo for more complete usage | ||
const layout = [ | ||
{ i: "a", x: 0, y: 0, w: 6, h: 12, isResizable: true, resizeHandles: ['se'] }, | ||
{ i: "b", x: 6, y: 0, w: 3, h: 6, isResizable: true, resizeHandles: ['se'] }, | ||
{ i: "c", x: 6, y: 0, w: 3, h: 6, isResizable: true, resizeHandles: ['se'] } | ||
]; | ||
|
||
export default function Home() { | ||
return ( | ||
<main className="flex min-h-screen flex-col items-center justify-between p-24"> | ||
<EditorView /> | ||
<main className="min-h-screen p-6"> | ||
|
||
<GridLayout | ||
className="layout" | ||
layout={layout} | ||
cols={12} | ||
rowHeight={30} | ||
width={1200} | ||
> | ||
<div className="bg-white p-3 rounded-md" key="a"> | ||
<EditorView /> | ||
</div> | ||
<div className="bg-white p-3 rounded-md" key="b">b</div> | ||
<div className="bg-white p-3 rounded-md" key="c">c</div> | ||
</GridLayout> | ||
</main> | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.