MCPcopy
hub / github.com/buxuku/SmartSub / SectionHeader

Function SectionHeader

renderer/components/SectionHeader.tsx:18–45  ·  view source on GitHub ↗
({
  icon: Icon,
  title,
  description,
  actions,
  className,
})

Source from the content-addressed store, hash-verified

16 * 收敛此前每个 Tab 各写一套头部导致的视觉不一致。
17 */
18const SectionHeader: React.FC<SectionHeaderProps> = ({
19 icon: Icon,
20 title,
21 description,
22 actions,
23 className,
24}) => (
25 <div className={cn('flex items-start justify-between gap-3', className)}>
26 <div className="flex min-w-0 items-start gap-3">
27 {Icon && (
28 <div className="flex h-9 w-9 shrink-0 items-center justify-center rounded-lg bg-primary/10 text-primary">
29 <Icon className="h-5 w-5" />
30 </div>
31 )}
32 <div className="min-w-0">
33 <h2 className="text-lg font-semibold leading-tight">{title}</h2>
34 {description && (
35 <p className="mt-1 text-sm text-muted-foreground">{description}</p>
36 )}
37 </div>
38 </div>
39 {actions && (
40 <div className="flex shrink-0 flex-wrap items-center justify-end gap-2">
41 {actions}
42 </div>
43 )}
44 </div>
45);
46
47export default SectionHeader;

Callers

nothing calls this directly

Calls 1

cnFunction · 0.90

Tested by

no test coverage detected