fix(sidebar): raise mobile sidebar above sticky lesson headers

Restore lesson/exercise page header z-100 stacking and fix the overlap
by lifting the mobile sidebar sheet and overlay to z-150, matching the
desktop course sidebar.

Co-authored-by: Rotimi Best <[email protected]>
This commit is contained in:
Cursor Agent
2026-07-10 05:15:39 +00:00
co-authored by Rotimi Best
parent daae6c1d40
commit 553c126e3c
4 changed files with 10 additions and 4 deletions
@@ -405,7 +405,7 @@
} }
</script> </script>
<Page.Header isSticky={true} class="top-12! min-h-[36px]"> <Page.Header isSticky={true} class="top-12! z-100! min-h-[36px]">
<Page.HeaderContent> <Page.HeaderContent>
<Page.Title class="flex flex-col gap-2"> <Page.Title class="flex flex-col gap-2">
<span>{exerciseDisplayTitle}</span> <span>{exerciseDisplayTitle}</span>
@@ -387,7 +387,7 @@
}} }}
/> />
<Page.Header isSticky={true} class="top-12! min-h-[36px]"> <Page.Header>
<Page.HeaderContent> <Page.HeaderContent>
<LessonPageEditHeader <LessonPageEditHeader
{mode} {mode}
@@ -32,17 +32,19 @@
class: className, class: className,
side = 'right', side = 'right',
portalProps, portalProps,
overlayClass,
children, children,
...restProps ...restProps
}: WithoutChildrenOrChild<SheetPrimitive.ContentProps> & { }: WithoutChildrenOrChild<SheetPrimitive.ContentProps> & {
portalProps?: SheetPrimitive.PortalProps; portalProps?: SheetPrimitive.PortalProps;
side?: Side; side?: Side;
overlayClass?: string;
children: Snippet; children: Snippet;
} = $props(); } = $props();
</script> </script>
<SheetPrimitive.Portal {...portalProps}> <SheetPrimitive.Portal {...portalProps}>
<SheetOverlay /> <SheetOverlay class={overlayClass} />
<SheetPrimitive.Content <SheetPrimitive.Content
bind:ref bind:ref
data-slot="sheet-content" data-slot="sheet-content"
+5 -1
View File
@@ -39,7 +39,11 @@
data-sidebar="sidebar" data-sidebar="sidebar"
data-slot="sidebar" data-slot="sidebar"
data-mobile="true" data-mobile="true"
class="ui:bg-sidebar ui:text-sidebar-foreground ui:w-(--sidebar-width) ui:p-0 ui:[&>button]:hidden" overlayClass="ui:z-150!"
class={cn(
'ui:bg-sidebar ui:text-sidebar-foreground ui:w-(--sidebar-width) ui:z-150! ui:p-0 ui:[&>button]:hidden',
className
)}
style="--sidebar-width: {SIDEBAR_WIDTH_MOBILE};" style="--sidebar-width: {SIDEBAR_WIDTH_MOBILE};"
{side} {side}
> >