import { HeaderConfig } from '../../types/navigation'; import { cn } from '../../utils'; export interface HeaderSkeletonProps { config?: HeaderConfig; } /** * Loading skeleton mirroring the unified ODS top-navigation geometry * (`TopNavigation`, Figma 2797-5978): 48px mobile / 56px md+, cell model. * Keep in sync with `header.tsx` — a diverging skeleton makes the * skeleton→live handoff jump. */ export function HeaderSkeleton({ config }: HeaderSkeletonProps) { const showNavigation = config?.navigation && config.navigation.items.length > 0; const showActions = config?.actions?.right && config.actions.right.length > 0; const showMobileMenu = config?.mobile?.enabled; const showLeftActions = !!config?.actions?.left; return (
{/* Leading cells: admin toggle / burger */} {showLeftActions && (
)} {showMobileMenu && (
)} {/* Logo zone */}
{/* Center: navigation links (desktop only) */}
{showNavigation && ( <>
)}
{/* CTA zone */} {showActions && (
)} {/* Mingo cell */} {config?.mingo?.enabled && (
)}
); }