feat: adjust mask background styling

- Updated ChatInterface to improve the gradient mask and backdrop filter for better visual effects.
- Refined ChatMoreDropdown by removing unnecessary padding from the DropdownMenuSubContent for a cleaner layout.

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei
2025-10-06 00:25:32 +08:00
parent 4996336e9f
commit 6f6b0ac953
2 changed files with 23 additions and 8 deletions
@@ -377,13 +377,28 @@ const ChatInterfaceContent = ({ centerInputOnEmpty }: ChatInterfaceProps) => {
</div>
{(!centerInputOnEmpty || hasMessages) && (
<div
className="bg-background pointer-events-none absolute inset-x-0 bottom-0 z-0 opacity-90"
style={{
maskImage: "linear-gradient(to bottom, transparent, black)",
height: bottomPanelHeight,
}}
/>
<div className="absolute inset-x-0 bottom-0 isolate">
<div
className="pointer-events-none absolute inset-x-0 bottom-0 h-44"
style={{
maskImage: "linear-gradient(to top, black 70%, rgba(0,0,0,.6) 85%, transparent)",
WebkitMaskImage:
"linear-gradient(to top, black 60%, rgba(0,0,0,.6) 85%, transparent)",
backdropFilter: "blur(22px) brightness(0.6)",
WebkitBackdropFilter: "blur(22px) brightness(0.6)",
}}
/>
<div
className="from-background/20 to-background/0 pointer-events-none absolute inset-x-0 bottom-0 h-60 bg-gradient-to-b"
style={{
maskImage: "linear-gradient(to top, black 20%, transparent 70%)",
WebkitMaskImage: "linear-gradient(to top, black 20%, transparent 70%)",
backdropFilter: "blur(50px) saturate(130%)",
WebkitBackdropFilter: "blur(50px) saturate(130%)",
}}
/>
</div>
)}
</div>
</GlobalFileDropZone>
@@ -127,7 +127,7 @@ export const ChatMoreDropdown = ({
<i className="i-mgc-history-cute-re size-4" />
<span>Chat History</span>
</DropdownMenuSubTrigger>
<DropdownMenuSubContent className="max-h-96 w-72 overflow-y-auto p-2">
<DropdownMenuSubContent className="max-h-96 w-72 overflow-y-auto">
{loading ? (
<div className="flex items-center justify-center py-8">
<i className="i-mgc-loading-3-cute-re text-text-secondary size-5 animate-spin" />