diff --git a/src/app/globals.css b/src/app/globals.css index 5b54ed500b..ab42b2b10a 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -40,7 +40,7 @@ --color-bg-primary: #f9f9fb; --color-bg-subtle: #f0f0f5; --color-surface: #ffffff; - --color-sidebar: rgba(245, 245, 250, 0.8); + --color-sidebar: #f5f5fa; --color-border: rgba(0, 0, 0, 0.08); --color-text-main: #1a1a2e; --color-text-primary: #1a1a2e; @@ -59,7 +59,7 @@ --color-bg-primary: #0b0e14; --color-bg-subtle: #111520; --color-surface: #161b22; - --color-sidebar: rgba(16, 20, 30, 0.8); + --color-sidebar: #10141e; --color-border: rgba(255, 255, 255, 0.08); --color-text-main: #e6e6ef; --color-text-primary: #e6e6ef; diff --git a/src/shared/components/Header.tsx b/src/shared/components/Header.tsx index fa7c09536a..9102ad1e2a 100644 --- a/src/shared/components/Header.tsx +++ b/src/shared/components/Header.tsx @@ -143,11 +143,9 @@ export default function Header({ onMenuClick, showMenuButton = true }) { return (
{/* Mobile menu button */} diff --git a/src/shared/components/ProxyLogger.tsx b/src/shared/components/ProxyLogger.tsx index 665956ef58..8e97cb425d 100644 --- a/src/shared/components/ProxyLogger.tsx +++ b/src/shared/components/ProxyLogger.tsx @@ -50,6 +50,7 @@ export default function ProxyLogger() { const [selectedLog, setSelectedLog] = useState(null); const intervalRef = useRef(null); const hasLoadedRef = useRef(false); + const logsSignatureRef = useRef(""); const [visibleColumns, setVisibleColumns] = useState(() => { if (typeof window === "undefined") return DEFAULT_VISIBLE; @@ -88,7 +89,12 @@ export default function ProxyLogger() { const res = await fetch(`/api/usage/proxy-logs?${params}`); if (res.ok) { const data = await res.json(); - setLogs(data); + // Skip re-render if data hasn't changed (#1369 GPU perf) + const sig = JSON.stringify(data.map?.((l: any) => l.id) ?? []); + if (sig !== logsSignatureRef.current) { + logsSignatureRef.current = sig; + setLogs(data); + } } } catch (error) { console.error("Failed to fetch proxy logs:", error); diff --git a/src/shared/components/RequestLoggerV2.tsx b/src/shared/components/RequestLoggerV2.tsx index 48f0c7e7e4..f5047b4640 100644 --- a/src/shared/components/RequestLoggerV2.tsx +++ b/src/shared/components/RequestLoggerV2.tsx @@ -163,6 +163,7 @@ export default function RequestLoggerV2() { const [detailLoggingLoading, setDetailLoggingLoading] = useState(false); const intervalRef = useRef(null); const hasLoadedRef = useRef(false); + const logsSignatureRef = useRef(""); const [providerNodes, setProviderNodes] = useState([]); // Column visibility with localStorage persistence @@ -205,7 +206,12 @@ export default function RequestLoggerV2() { const res = await fetch(`/api/usage/call-logs?${params}`); if (res.ok) { const data = await res.json(); - setLogs(data); + // Skip re-render if data hasn't changed (#1369 GPU perf) + const sig = JSON.stringify(data.map?.((l: any) => l.id) ?? []); + if (sig !== logsSignatureRef.current) { + logsSignatureRef.current = sig; + setLogs(data); + } } } catch (error) { console.error("Failed to fetch call logs:", error); diff --git a/src/shared/components/Sidebar.tsx b/src/shared/components/Sidebar.tsx index 5e59ff549b..ae1289617e 100644 --- a/src/shared/components/Sidebar.tsx +++ b/src/shared/components/Sidebar.tsx @@ -192,7 +192,7 @@ export default function Sidebar({ <>