chore: freeze local demo baseline
This commit is contained in:
@@ -5,7 +5,7 @@ import { useApp } from "@/lib/store";
|
||||
import ChatMessage from "./ChatMessage";
|
||||
import ChatInput from "./ChatInput";
|
||||
import RawTraceExplorer from "./RawTraceExplorer";
|
||||
import { Sparkles, Workflow } from "lucide-react";
|
||||
import { FileText, Blocks, ShieldCheck, Users, Workflow } from "lucide-react";
|
||||
|
||||
export default function ChatPanel() {
|
||||
const { messages, sessionId } = useApp();
|
||||
@@ -22,20 +22,19 @@ export default function ChatPanel() {
|
||||
<div className="flex-1 min-h-0 overflow-y-scroll scroll-shadow">
|
||||
{messages.length === 0 ? (
|
||||
<div className="flex flex-col items-center justify-center h-full">
|
||||
<div className="w-14 h-14 rounded-2xl bg-gradient-to-br from-[#002fa7] to-[#4070ff] flex items-center justify-center mb-4 shadow-lg shadow-[#002fa7]/15">
|
||||
<Sparkles className="w-7 h-7 text-white" />
|
||||
</div>
|
||||
<div className="xingbang-chat-mark" aria-hidden="true">兴</div>
|
||||
<p className="text-[10px] font-semibold tracking-[0.18em] text-[#6f8a7c] mb-2">兴邦金租 · 项目评审协同</p>
|
||||
<h2 className="text-lg font-semibold text-gray-800 mb-1">
|
||||
Hi, how can I help?
|
||||
从项目事实开始评审
|
||||
</h2>
|
||||
<p className="text-[13px] text-gray-400 max-w-xs text-center leading-relaxed">
|
||||
Ask me anything, or try{" "}
|
||||
<span className="text-[#ff6723] font-medium">"查询北京天气"</span>
|
||||
<p className="text-[13px] text-gray-400 max-w-md text-center leading-relaxed">
|
||||
选择一个工作问题,或在下方输入项目资料与任务。
|
||||
</p>
|
||||
<div className="flex flex-wrap gap-2 mt-5 max-w-md justify-center">
|
||||
{["你好,介绍一下自己", "查询北京天气", "帮我写一段Python代码"].map((hint) => (
|
||||
<QuickHint key={hint} text={hint} />
|
||||
))}
|
||||
<div className="grid grid-cols-2 gap-2 mt-5 max-w-lg w-full px-4">
|
||||
<QuickHint icon={ShieldCheck} text="帮我做一次项目风险研判" />
|
||||
<QuickHint icon={FileText} text="根据研判快照建立评审底稿" />
|
||||
<QuickHint icon={Users} text="整理上会待办并推荐主审员" />
|
||||
<QuickHint icon={Blocks} text="核验租赁物与增信覆盖能力" />
|
||||
</div>
|
||||
</div>
|
||||
) : (
|
||||
@@ -72,13 +71,14 @@ export default function ChatPanel() {
|
||||
);
|
||||
}
|
||||
|
||||
function QuickHint({ text }: { text: string }) {
|
||||
function QuickHint({ text, icon: Icon }: { text: string; icon: typeof ShieldCheck }) {
|
||||
const { sendMessage, isStreaming } = useApp();
|
||||
return (
|
||||
<button
|
||||
onClick={() => !isStreaming && sendMessage(text)}
|
||||
className="px-3 py-1.5 rounded-full text-[12px] text-gray-500 bg-white/60 border border-black/[0.04] hover:bg-white hover:shadow-sm hover:text-gray-700 transition-all"
|
||||
className="min-h-11 flex items-center gap-2 px-3 py-2 rounded-lg text-left text-[12px] leading-snug text-gray-600 bg-white/65 border border-black/[0.05] hover:bg-white hover:shadow-sm hover:text-[#17634c] transition-all"
|
||||
>
|
||||
<Icon className="w-4 h-4 shrink-0 text-[#4f8a70]" />
|
||||
{text}
|
||||
</button>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user