Add reusable multi-session skill and five-page project workbench
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
import { Link } from 'react-router-dom'
|
||||
import { ArrowRight } from 'lucide-react'
|
||||
import { Button } from '@/components/ui/button'
|
||||
import { PageHeading, Panel, Empty, Reports } from '@/components/shared'
|
||||
import { useWorkbench } from '@/lib/context'
|
||||
import { date } from '@/lib/types'
|
||||
export default function Decisions() {
|
||||
const { state } = useWorkbench()
|
||||
const pending = state.tasks.filter(t => t.decision)
|
||||
return <div className="space-y-6"><PageHeading title="方案与决策" description="将待决定事项与方案记录集中管理。" action={<Button asChild><Link to="/communication">进入专门会话讨论 <ArrowRight /></Link></Button>} />
|
||||
<Panel title="等待决定" description="以下内容由工作包登记;聊天中的来源字段不代表人类批准。">{pending.length ? <div className="divide-y">{pending.map(t => <article key={t.id} className="py-5 first:pt-0 last:pb-0"><h3 className="font-medium">{t.id} · {t.name}</h3><p className="mt-3 whitespace-pre-wrap text-sm leading-7">{t.decision}</p><p className="mt-3 text-xs text-muted-foreground">更新于 {date(t.updated)}</p></article>)}</div> : <Empty>当前没有登记待决策事项。</Empty>}</Panel>
|
||||
<Panel title="方案与决策记录"><Reports events={state.events.filter(e => /decision|proposal|方案|决策/.test(e.kind))} /></Panel>
|
||||
</div>
|
||||
}
|
||||
Reference in New Issue
Block a user