- Vite 6 + React 19 + TypeScript + Tailwind 4 + Zustand 5 - Login page with JWT auth - Chat interface: MessageList, ChatInput, ChatContainer - WebSocket hook with auto-reconnect and exponential backoff - Sidebar with new chat button + session navigation - Admin dashboard placeholder - 57 modules, 242KB JS, TypeScript zero errors
19 lines
576 B
TypeScript
19 lines
576 B
TypeScript
import { ReactNode } from 'react'
|
|
import { useAuthStore } from '../../store/authStore'
|
|
import Header from './Header'
|
|
import Sidebar from './Sidebar'
|
|
|
|
export default function AppLayout({ children }: { children: ReactNode }) {
|
|
const { username, logout } = useAuthStore()
|
|
|
|
return (
|
|
<div className="h-screen flex flex-col bg-gray-950 text-gray-100">
|
|
<Header username={username} onLogout={logout} />
|
|
<div className="flex-1 flex overflow-hidden">
|
|
<Sidebar />
|
|
<main className="flex-1 overflow-auto">{children}</main>
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|