From 1317a73e9a727e6fb2d1547542fb976142da1646 Mon Sep 17 00:00:00 2001 From: Denozordec Date: Fri, 17 Jul 2026 23:56:35 +0700 Subject: [PATCH] refactor: update AppShell and sidebar components for improved design consistency Removed unused utility functions from the AppShell component and updated the sidebar width to a fixed value for better layout control. Revised the UI design documentation to clarify the shared App Shell chrome specifications and ensure alignment with design standards. Enhanced the sidebar configuration to reflect the new width and styling guidelines. --- apps/web/src/components/app-switcher.tsx | 2 +- apps/web/src/components/layout/app-shell.tsx | 9 +-------- docs/ui-design-contract.md | 18 +++++++++++------- packages/ui/src/components/sidebar.tsx | 2 +- 4 files changed, 14 insertions(+), 17 deletions(-) diff --git a/apps/web/src/components/app-switcher.tsx b/apps/web/src/components/app-switcher.tsx index d11a94e..e346139 100644 --- a/apps/web/src/components/app-switcher.tsx +++ b/apps/web/src/components/app-switcher.tsx @@ -20,7 +20,7 @@ import { } from '@/lib/app-switcher-config' import { useAppSwitcherConfig } from '@/hooks/use-app-switcher' -/** Sidebar app switcher — same chrome as CFDM / vps-tracker. @see https://reui.io/preview/base/app-shell-12 */ +/** Sidebar app switcher — shared chrome etalon EvoBGP. @see https://reui.io/preview/base/app-shell-12 */ export function AppSwitcher() { const { isMobile } = useSidebar() const { config, isLoading } = useAppSwitcherConfig() diff --git a/apps/web/src/components/layout/app-shell.tsx b/apps/web/src/components/layout/app-shell.tsx index bb4a1d2..0726cd3 100644 --- a/apps/web/src/components/layout/app-shell.tsx +++ b/apps/web/src/components/layout/app-shell.tsx @@ -38,7 +38,6 @@ import { } from '@evobgp/ui/components/breadcrumb' import { Separator } from '@evobgp/ui/components/separator' import { TooltipProvider } from '@evobgp/ui/components/tooltip' -import { cn } from '@evobgp/ui/lib/utils' import { Link, useRouterState } from '@tanstack/react-router' import type { ComponentType, CSSProperties, ReactNode } from 'react' @@ -122,7 +121,7 @@ const COMMAND_ITEMS: CommandPaletteItem[] = ALL_NAV_ITEMS.map((item) => ({ })) /** - * Shared ops chrome — tokens match CFDM / vps-tracker. + * Shared ops chrome etalon for CFDM / vps-tracker. * @see https://reui.io/preview/base/app-shell-12 * @see docs/ui-design-contract.md — Shared App Shell chrome */ @@ -142,12 +141,6 @@ export function AppShell({ children }: { children: ReactNode }) { return (