fix: widen collapsed sidebar to 64px, prevent header flash on refresh

Collapsed width 56px→64px to stop clipping site picker badge and icons.
Return null while auth is loading on site pages to prevent brief flash
of the public floating header before the sidebar layout renders.
This commit is contained in:
Usman Baig
2026-03-18 16:51:01 +01:00
parent 5c8f334017
commit 6fcb6df295
2 changed files with 7 additions and 2 deletions

View File

@@ -95,7 +95,12 @@ function LayoutInner({ children }: { children: React.ReactNode }) {
return <LoadingOverlay logoSrc="/pulse_icon_no_margins.png" title="Pulse" portal={false} /> return <LoadingOverlay logoSrc="/pulse_icon_no_margins.png" title="Pulse" portal={false} />
} }
// Authenticated site pages: full Dokploy-style layout (sidebar + utility bar) // While auth is loading on a site page, render nothing to prevent flash of public header
if (auth.loading && isSitePage) {
return null
}
// Authenticated site pages: full sidebar layout
// DashboardShell inside children handles everything // DashboardShell inside children handles everything
if (isAuthenticated && isSitePage) { if (isAuthenticated && isSitePage) {
return ( return (

View File

@@ -23,7 +23,7 @@ import {
const SIDEBAR_KEY = 'pulse_sidebar_collapsed' const SIDEBAR_KEY = 'pulse_sidebar_collapsed'
const EXPANDED = 256 const EXPANDED = 256
const COLLAPSED = 56 const COLLAPSED = 64
type IconWeight = 'thin' | 'light' | 'regular' | 'bold' | 'fill' | 'duotone' type IconWeight = 'thin' | 'light' | 'regular' | 'bold' | 'fill' | 'duotone'