File tree Expand file tree Collapse file tree 1 file changed +10
-6
lines changed
Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -1523,6 +1523,12 @@ let make = (~bundleBaseUrl: string, ~versions: array<string>) => {
15231523 let (searchParams , _ ) = ReactRouter .useSearchParams ()
15241524 let containerRef = React .useRef (Nullable .null )
15251525 let editorRef : React .ref <option <CodeMirror .editorInstance >> = React .useRef (None )
1526+ let (_ , setScrollLock ) = ScrollLockContext .useScrollLock ()
1527+
1528+ React .useEffect (() => {
1529+ setScrollLock (_ => true )
1530+ None
1531+ }, [])
15261532
15271533 let versions =
15281534 versions
@@ -1990,9 +1996,7 @@ let make = (~bundleBaseUrl: string, ~versions: array<string>) => {
19901996 <button key = {Int .toString (i )} onClick className disabled > {title } </button >
19911997 })
19921998
1993- <main className = {
1994- "flex flex-col bg-gray-100 text-gray-40 text-14 overflow-scroll playground-scrollbar mt-16"
1995- }>
1999+ <main className = {"flex flex-col bg-gray-100 text-gray-40 text-14 overflow-hidden mt-16" }>
19962000 <ControlPanel
19972001 actionIndicatorKey = {Int .toString (actionCount )}
19982002 state = compilerState
@@ -2007,9 +2011,9 @@ let make = (~bundleBaseUrl: string, ~versions: array<string>) => {
20072011 // Left Panel
20082012 <div
20092013 ref = {ReactDOM .Ref .domRef ((Obj .magic (leftPanelRef ): React .ref <Nullable .t <Dom .element >>))}
2010- className = {` overflow-scroll playground-scrollbar ${layout == Column ? "h-2/4" : "h-full!" } ${layout == Column
2011- ? "w-full "
2012- : "w-[50%]" }` }
2014+ className = {` overflow-scroll playground-scrollbar ${layout == Column
2015+ ? "h-2/4 "
2016+ : "h-full!" } ${layout == Column ? "w-full" : " w-[50%]" }` }
20132017 >
20142018 <div
20152019 className = "bg-gray-100 h-full"
You can’t perform that action at this time.
0 commit comments