File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -18,20 +18,23 @@ export const LayoutSidebar = ({
1818} : LayoutSidebarProps ) => {
1919 const { activeSidebar } = useSidebarManagerSnapshot ( )
2020
21+ if ( ! activeSidebar ?. component ) return null
22+
2123 return (
2224 < >
2325 < ResizableHandle withHandle />
2426 < ResizablePanel
2527 id = "panel-side"
2628 key = { activeSidebar ?. id ?? 'default' }
2729 order = { order }
28- defaultSize = { ! ! activeSidebar ?. component ? defaultSize : 0 }
29- minSize = { ! ! activeSidebar ?. component ? minSize : 0 }
30- maxSize = { ! ! activeSidebar ?. component ? maxSize : 0 }
30+ defaultSize = { defaultSize }
31+ minSize = { minSize }
32+ maxSize = { maxSize }
3133 className = { cn (
3234 'border-l bg fixed z-40 right-0 top-0 bottom-0' ,
33- 'w-screen h-[100dvh]' ,
34- 'md:absolute md:h-auto md:w-3/4' ,
35+ 'h-[100dvh]' ,
36+ 'md:absolute md:h-auto md:w-1/2' ,
37+ 'lg:w-2/5' ,
3538 'xl:relative xl:border-l-0'
3639 ) }
3740 >
You can’t perform that action at this time.
0 commit comments