diff --git a/web/src/app/globals.css b/web/src/app/globals.css index 9013571..b043a79 100644 --- a/web/src/app/globals.css +++ b/web/src/app/globals.css @@ -25,10 +25,12 @@ --bl-accent-muted: var(--nl-accent-muted); --bl-surface-card: var(--nl-surface-card); --bl-surface-muted: var(--nl-surface-muted); + --bl-surface-sidebar: var(--nl-surface-sidebar); --bl-text-primary: var(--nl-text-primary); --bl-text-secondary: var(--nl-text-secondary); --bl-text-tertiary: var(--nl-text-tertiary); --bl-border: var(--nl-border-default); + --bl-overlay-scrim: var(--nl-overlay-scrim); --bl-success: var(--nl-status-success); --bl-success-muted: var(--nl-success-muted); --bl-success-border: var(--nl-status-success); @@ -92,6 +94,7 @@ button { .main-panel { min-width: 0; padding: var(--nl-space-8); + padding-left: calc(var(--bl-app-sidebar-width, 280px) + var(--nl-space-8)); } .app-shell > .sidebar { diff --git a/web/src/components/AppShell.tsx b/web/src/components/AppShell.tsx index 6050cb2..24b8cad 100644 --- a/web/src/components/AppShell.tsx +++ b/web/src/components/AppShell.tsx @@ -3,7 +3,14 @@ import { type ReactNode, useState, useCallback, useEffect } from "react"; import { usePathname } from "next/navigation"; import { Sidebar } from "@/components/Sidebar"; -import { Button, Card } from "@/components/ui/Primitives"; +import { + AppShell as AppShellFrame, + AppShellMain, + AppShellMobileToggle, + AppShellOverlay, + AppShellPageHeader, + AppShellSkipLink, +} from "@/components/ui/Primitives"; export function AppShell({ title, @@ -27,47 +34,15 @@ export function AppShell({ const close = useCallback(() => setSidebarOpen(false), []); return ( -
- - Skip to main content - - - + + + {children} + + ); } diff --git a/web/src/components/Sidebar.tsx b/web/src/components/Sidebar.tsx index 1545622..8ae65b0 100644 --- a/web/src/components/Sidebar.tsx +++ b/web/src/components/Sidebar.tsx @@ -1,10 +1,16 @@ "use client"; -import Link from "next/link"; import { usePathname } from "next/navigation"; import { House, Search, Settings, Sparkles, FolderKanban, ShieldCheck, MessageCircle, Brain } from "lucide-react"; import { PRODUCT_NAME } from "@/lib/product-config"; import { isFeatureEnabled } from "@/lib/feature-flags"; +import { + AppShellNav, + AppShellNavItem, + AppShellSidebar, + Badge, + Panel, +} from "@/components/ui/Primitives"; const navItems: { href: string; label: string; icon: typeof House; flag?: string }[] = [ { href: "/dashboard", label: "Dashboard", icon: House }, @@ -21,56 +27,47 @@ export function Sidebar({ open }: { open?: boolean }) { const pathname = usePathname() ?? ""; return ( - + ); } diff --git a/web/src/components/ui/Primitives.tsx b/web/src/components/ui/Primitives.tsx index e85c465..af57bde 100644 --- a/web/src/components/ui/Primitives.tsx +++ b/web/src/components/ui/Primitives.tsx @@ -1,4 +1,13 @@ import { + AppShell as BytelystAppShell, + AppShellMain as BytelystAppShellMain, + AppShellMobileToggle as BytelystAppShellMobileToggle, + AppShellNav as BytelystAppShellNav, + AppShellNavItem as BytelystAppShellNavItem, + AppShellOverlay as BytelystAppShellOverlay, + AppShellPageHeader as BytelystAppShellPageHeader, + AppShellSidebar as BytelystAppShellSidebar, + AppShellSkipLink as BytelystAppShellSkipLink, Badge as BytelystBadge, Button as BytelystButton, Card as BytelystCard, @@ -53,6 +62,15 @@ import { TooltipContent, TooltipProvider, TooltipTrigger, + type AppShellMainProps, + type AppShellMobileToggleProps, + type AppShellNavItemProps, + type AppShellNavProps, + type AppShellOverlayProps, + type AppShellPageHeaderProps, + type AppShellProps, + type AppShellSidebarProps, + type AppShellSkipLinkProps, type BadgeProps, type ButtonProps, type CardProps, @@ -144,6 +162,42 @@ const statusToneMap: Record = { review: "accent", }; +export function AppShell({ className, ...props }: AppShellProps) { + return ; +} + +export function AppShellSkipLink({ className, ...props }: AppShellSkipLinkProps) { + return ; +} + +export function AppShellMobileToggle({ className, ...props }: AppShellMobileToggleProps) { + return ; +} + +export function AppShellOverlay({ className, ...props }: AppShellOverlayProps) { + return ; +} + +export function AppShellSidebar({ className, ...props }: AppShellSidebarProps) { + return ; +} + +export function AppShellMain({ className, ...props }: AppShellMainProps) { + return ; +} + +export function AppShellPageHeader({ className, ...props }: AppShellPageHeaderProps) { + return ; +} + +export function AppShellNav({ className, ...props }: AppShellNavProps) { + return ; +} + +export function AppShellNavItem({ className, ...props }: AppShellNavItemProps) { + return ; +} + export function getStatusTone(status: NoteLettStatus): StatusTone { return statusToneMap[status]; }