mirror of
https://github.com/chriswritescode-dev/opencode-manager.git
synced 2026-12-05 12:24:30 +01:00
21 lines
621 B
TypeScript
21 lines
621 B
TypeScript
import { useActivityWindowMs } from '@/hooks/useActiveWork'
|
|
import { ActivityList } from '@/components/activity/ActivityList'
|
|
|
|
/**
|
|
* A compact, self-titled Activity section that renders nothing when empty.
|
|
* Reads the network through `useActiveWork`, so it must only be mounted while visible.
|
|
*/
|
|
export function CompactActivityList({ onNavigate }: { onNavigate: (path: string) => void }) {
|
|
const windowMs = useActivityWindowMs()
|
|
|
|
return (
|
|
<ActivityList
|
|
windowMs={windowMs}
|
|
title="Activity"
|
|
hideWhenEmpty
|
|
variant="compact"
|
|
onNavigate={(item) => onNavigate(item.path)}
|
|
/>
|
|
)
|
|
}
|