feat(ui): 优化 Chat 页面 Header 布局
- 移除左上角 "Chat" 标题 - Token 使用情况移至左侧 - 压缩按钮添加文字标签,更直观 - 工具栏按钮保持在右侧
This commit is contained in:
@@ -158,19 +158,25 @@ export function ContextUsage({
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
className={cn(
|
||||
'h-5 px-1.5 text-xs',
|
||||
'h-5 px-1.5 text-xs gap-1',
|
||||
shouldCompress
|
||||
? 'text-amber-500 hover:text-amber-400 hover:bg-amber-500/10'
|
||||
: 'text-fg-muted hover:text-fg-secondary hover:bg-surface-muted'
|
||||
)}
|
||||
onClick={handleCompress}
|
||||
disabled={compressing}
|
||||
title="压缩对话上下文"
|
||||
title="压缩对话上下文以释放 token 空间"
|
||||
>
|
||||
{compressing ? (
|
||||
<RefreshCw size={12} className="animate-spin" />
|
||||
<>
|
||||
<RefreshCw size={12} className="animate-spin" />
|
||||
<span>压缩中</span>
|
||||
</>
|
||||
) : (
|
||||
<Zap size={12} />
|
||||
<>
|
||||
<Zap size={12} />
|
||||
<span>压缩</span>
|
||||
</>
|
||||
)}
|
||||
</Button>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user