From 6b1b16a80ee0c32959950bfc280dd06ed255d682 Mon Sep 17 00:00:00 2001 From: diegosouzapw Date: Tue, 17 Feb 2026 12:16:41 -0300 Subject: [PATCH] refactor(dashboard): rename Usage to Request Logs and extract Limits & Quotas page - Rename 'Usage' sidebar item to 'Request Logs' with receipt_long icon - Add new 'Limits & Quotas' sidebar item with tune icon - Extract ProviderLimits, RateLimitStatus, SessionsTab to dedicated /dashboard/limits page - Simplify usage page to only Logger and Proxy tabs - Update HomePageClient Quick Start cross-reference text --- .../(dashboard)/dashboard/HomePageClient.tsx | 2 +- src/app/(dashboard)/dashboard/limits/page.tsx | 19 +++++++++++++++++++ src/app/(dashboard)/dashboard/usage/page.tsx | 17 ++--------------- src/shared/components/Sidebar.tsx | 13 +++++++++++-- 4 files changed, 33 insertions(+), 18 deletions(-) create mode 100644 src/app/(dashboard)/dashboard/limits/page.tsx diff --git a/src/app/(dashboard)/dashboard/HomePageClient.tsx b/src/app/(dashboard)/dashboard/HomePageClient.tsx index 5c0cbd666f..82780967ed 100644 --- a/src/app/(dashboard)/dashboard/HomePageClient.tsx +++ b/src/app/(dashboard)/dashboard/HomePageClient.tsx @@ -204,7 +204,7 @@ export default function HomePageClient({ machineId }) {

Track tokens, cost and errors in{" "} - Usage + Request Logs {" "} and{" "} diff --git a/src/app/(dashboard)/dashboard/limits/page.tsx b/src/app/(dashboard)/dashboard/limits/page.tsx new file mode 100644 index 0000000000..5d29d0efbb --- /dev/null +++ b/src/app/(dashboard)/dashboard/limits/page.tsx @@ -0,0 +1,19 @@ +"use client"; + +import { Suspense } from "react"; +import { CardSkeleton } from "@/shared/components"; +import ProviderLimits from "../usage/components/ProviderLimits"; +import RateLimitStatus from "../usage/components/RateLimitStatus"; +import SessionsTab from "../usage/components/SessionsTab"; + +export default function LimitsPage() { + return ( +

+ }> + + + + +
+ ); +} diff --git a/src/app/(dashboard)/dashboard/usage/page.tsx b/src/app/(dashboard)/dashboard/usage/page.tsx index b8d74006bc..69727c0b39 100644 --- a/src/app/(dashboard)/dashboard/usage/page.tsx +++ b/src/app/(dashboard)/dashboard/usage/page.tsx @@ -1,10 +1,7 @@ "use client"; -import { useState, Suspense } from "react"; -import { RequestLoggerV2, ProxyLogger, CardSkeleton, SegmentedControl } from "@/shared/components"; -import ProviderLimits from "./components/ProviderLimits"; -import SessionsTab from "./components/SessionsTab"; -import RateLimitStatus from "./components/RateLimitStatus"; +import { useState } from "react"; +import { RequestLoggerV2, ProxyLogger, SegmentedControl } from "@/shared/components"; export default function UsagePage() { const [activeTab, setActiveTab] = useState("logs"); @@ -15,22 +12,12 @@ export default function UsagePage() { options={[ { value: "logs", label: "Logger" }, { value: "proxy-logs", label: "Proxy" }, - { value: "limits", label: "Limits" }, ]} value={activeTab} onChange={setActiveTab} /> {/* Content */} - {activeTab === "limits" && ( -
- }> - - - - -
- )} {activeTab === "logs" && } {activeTab === "proxy-logs" && } diff --git a/src/shared/components/Sidebar.tsx b/src/shared/components/Sidebar.tsx index 7ccfca9a27..9140d32694 100644 --- a/src/shared/components/Sidebar.tsx +++ b/src/shared/components/Sidebar.tsx @@ -16,9 +16,10 @@ const navItems = [ { href: "/dashboard/endpoint", label: "Endpoint", icon: "api" }, { href: "/dashboard/providers", label: "Providers", icon: "dns" }, { href: "/dashboard/combos", label: "Combos", icon: "layers" }, - { href: "/dashboard/usage", label: "Usage", icon: "bar_chart" }, + { href: "/dashboard/usage", label: "Request Logs", icon: "receipt_long" }, { href: "/dashboard/costs", label: "Costs", icon: "account_balance_wallet" }, { href: "/dashboard/analytics", label: "Analytics", icon: "analytics" }, + { href: "/dashboard/limits", label: "Limits & Quotas", icon: "tune" }, { href: "/dashboard/health", label: "Health", icon: "health_and_safety" }, { href: "/dashboard/cli-tools", label: "CLI Tools", icon: "terminal" }, ]; @@ -38,7 +39,15 @@ const helpItems = [ }, ]; -export default function Sidebar({ onClose, collapsed = false, onToggleCollapse }: { onClose?: any; collapsed?: boolean; onToggleCollapse?: any }) { +export default function Sidebar({ + onClose, + collapsed = false, + onToggleCollapse, +}: { + onClose?: any; + collapsed?: boolean; + onToggleCollapse?: any; +}) { const pathname = usePathname(); const [showShutdownModal, setShowShutdownModal] = useState(false); const [showRestartModal, setShowRestartModal] = useState(false);