web/app/components/ui/section-header.tsxblame
View source
4dfd09b1export interface SectionHeaderProps {
4dfd09b2 title: string;
4dfd09b3 count?: number;
4dfd09b4 action?: React.ReactNode;
4dfd09b5 className?: string;
4dfd09b6}
4dfd09b7
4dfd09b8export function SectionHeader({
4dfd09b9 title,
4dfd09b10 count,
4dfd09b11 action,
4dfd09b12 className = "",
4dfd09b13}: SectionHeaderProps) {
4dfd09b14 return (
4dfd09b15 <div
4dfd09b16 className={`pb-2 mb-4 ${className}`}
4dfd09b17 style={{ borderBottom: "1px solid var(--border-subtle)" }}
4dfd09b18 >
4dfd09b19 <div className="flex items-center justify-between">
4dfd09b20 <div
4dfd09b21 className="flex items-center gap-2"
4dfd09b22 style={{
4dfd09b23 borderLeft: "3px solid var(--accent)",
4dfd09b24 paddingLeft: "12px",
4dfd09b25 }}
4dfd09b26 >
4dfd09b27 <h2
4dfd09b28 className="text-sm"
4dfd09b29 style={{
4dfd09b30 color: "var(--text-muted)",
4dfd09b31 textTransform: "uppercase",
4dfd09b32 letterSpacing: "0.05em",
4dfd09b33 }}
4dfd09b34 >
4dfd09b35 {title}
4dfd09b36 </h2>
4dfd09b37 {count !== undefined && (
4dfd09b38 <span className="text-xs" style={{ color: "var(--text-faint)" }}>
4dfd09b39 {count}
4dfd09b40 </span>
4dfd09b41 )}
4dfd09b42 </div>
4dfd09b43 {action && <div>{action}</div>}
4dfd09b44 </div>
4dfd09b45 </div>
4dfd09b46 );
4dfd09b47}