feat: P1 滚动到底部浮动按钮
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
dd70cadcc1
commit
a41f2fbf44
+14
-14
@@ -564,21 +564,21 @@ function App() {
|
||||
))}
|
||||
|
||||
<div ref={bottomRef} />
|
||||
</div>
|
||||
|
||||
{/* Scroll-to-bottom floating button */}
|
||||
{showScrollBtn && (
|
||||
<div className="absolute bottom-32 left-1/2 -translate-x-1/2 z-10">
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => bottomRef.current?.scrollIntoView({ behavior: "smooth" })}
|
||||
className="rounded-full bg-background border border-border shadow-md p-2 text-muted-foreground hover:text-foreground hover:bg-accent transition-colors"
|
||||
title="滚动到底部"
|
||||
>
|
||||
<ChevronDown className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
)}
|
||||
{/* Scroll-to-bottom floating button */}
|
||||
{showScrollBtn && (
|
||||
<div className="sticky bottom-4 flex justify-end pr-4 pointer-events-none">
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => bottomRef.current?.scrollIntoView({ behavior: "smooth" })}
|
||||
className="pointer-events-auto rounded-full bg-background/80 backdrop-blur border border-border shadow-md p-2 text-muted-foreground hover:text-foreground hover:bg-accent transition-colors"
|
||||
title="滚动到底部"
|
||||
>
|
||||
<ChevronDown className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* Control bar: tools (left) + model selector (right) */}
|
||||
<div className="shrink-0 border-t border-border px-4 pt-3 pb-0 flex items-center justify-between max-w-3xl mx-auto w-full">
|
||||
|
||||
Reference in New Issue
Block a user