18 lines
461 B
TypeScript
18 lines
461 B
TypeScript
|
|
interface TopbarProps {
|
||
|
|
title: string;
|
||
|
|
subtitle?: string;
|
||
|
|
actions?: React.ReactNode;
|
||
|
|
}
|
||
|
|
|
||
|
|
export function Topbar({ title, subtitle, actions }: TopbarProps) {
|
||
|
|
return (
|
||
|
|
<header className="topbar">
|
||
|
|
<div className="topbar-left">
|
||
|
|
<h1 className="topbar-title">{title}</h1>
|
||
|
|
{subtitle && <span className="topbar-sub">{subtitle}</span>}
|
||
|
|
</div>
|
||
|
|
{actions && <div className="topbar-actions">{actions}</div>}
|
||
|
|
</header>
|
||
|
|
);
|
||
|
|
}
|