Files
spsays-training/components/page-header.tsx
2026-05-05 01:08:19 +05:30

30 lines
687 B
TypeScript

import { ReadingSettings } from "@/components/reading-settings";
import { cn } from "@/lib/utils";
export function PageHeader({
children,
sticky = false,
className,
}: {
children: React.ReactNode;
sticky?: boolean;
className?: string;
}) {
return (
<header
className={cn(
"border-b border-border bg-card px-6",
sticky ? "py-4 sticky top-0 z-20" : "py-4",
className,
)}
>
<div className="max-w-5xl mx-auto flex items-start justify-between gap-4">
<div className="flex-1 min-w-0">{children}</div>
<div className="shrink-0 pt-1">
<ReadingSettings />
</div>
</div>
</header>
);
}