MCPcopy Create free account
hub / github.com/Donnadieu/Epstein-File-Explorer / AppShell

Function AppShell

client/src/App.tsx:56–107  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

54}
55
56function AppShell() {
57 const [, navigate] = useLocation();
58 const { showHelp, closeHelp } = useKeyboardShortcuts(navigate);
59
60 const style = {
61 "--sidebar-width": "16rem",
62 "--sidebar-width-icon": "3rem",
63 };
64
65 return (
66 <SidebarProvider style={style as React.CSSProperties}>
67 <div className="flex h-screen w-full">
68 <AppSidebar />
69 <div className="flex flex-col flex-1 min-w-0">
70 <header className="flex items-center justify-between gap-2 p-2 border-b sticky top-0 z-50 bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60">
71 <div className="flex items-center gap-3">
72 <SidebarTrigger data-testid="button-sidebar-toggle" />
73 <AppBreadcrumbs />
74 </div>
75 <div className="flex items-center">
76 <LiveCounter />
77 <NavActions />
78 <ThemeToggle />
79 </div>
80 </header>
81 <main className="flex-1 overflow-auto">
82 <Router />
83 </main>
84 </div>
85 </div>
86
87 <Dialog open={showHelp} onOpenChange={(open) => !open && closeHelp()}>
88 <DialogContent className="sm:max-w-md" data-testid="dialog-keyboard-shortcuts">
89 <DialogHeader>
90 <DialogTitle>Keyboard Shortcuts</DialogTitle>
91 <DialogDescription>
92 Navigate quickly using these keyboard shortcuts.
93 </DialogDescription>
94 </DialogHeader>
95 <div className="flex flex-col gap-1 mt-2">
96 {shortcutsList.map((s) => (
97 <div key={s.keys} className="flex items-center justify-between py-1.5 px-1">
98 <span className="text-sm text-muted-foreground">{s.label}</span>
99 <Kbd keys={s.keys} />
100 </div>
101 ))}
102 </div>
103 </DialogContent>
104 </Dialog>
105 </SidebarProvider>
106 );
107}
108
109function App() {
110 return (

Callers

nothing calls this directly

Calls 1

useKeyboardShortcutsFunction · 0.90

Tested by

no test coverage detected