How romanonyshko/car-selling-test-proj works
Auto Lincoln is a browser-based auto-parts catalogue admin panel. Users sign in, enter the protected application, and can view dashboard data, browse the catalogue section, or open support chat. The sampled code shows the router, session checks, dashboard query path, and chat state/socket layers. The README documents direct REST and WebSocket connections to the NestJS API; catalogue and several other sections are currently placeholders. Some UI and API internals were not sampled, so only documented or indexed relationships are shown.
Main entry points: routes.tsx Protected routes · DashboardPage.tsx Dashboard page · useSupportChat.ts Chat controller · apiClient.ts HTTP client
Components 21
App shell
- Application entry
src/app/App.tsx - Protected routes
src/app/router/routes.tsx - App layout
src/components/layout/AppLayout.tsx - Sidebar navigation
src/components/layout/Sidebar.tsx - Parts catalogue
src/pages/catalogue/CataloguePage.tsx - HTTP client
src/lib/apiClient.ts
Authentication
- Login form
src/features/auth/ui/LoginForm.tsx - Login mutations
src/features/auth/hooks/useLogin.ts - Session API
src/features/auth/api/authApi.ts - Session query
src/features/auth/api/authQueries.ts
Dashboard
- Dashboard page
src/pages/dashboard/DashboardPage.tsx - Dashboard query
src/features/dashboard/hooks/useDashboard.ts - Dashboard API
src/features/dashboard/api/dashboardApi.ts - Dashboard widgets
src/features/dashboard/ui
Support chat
- Support page
src/pages/support/SupportPage.tsx - Chat interface
src/features/support/ui/SupportChat.tsx - Chat controller
src/features/support/hooks/useSupportChat.ts - Chat state
src/features/support/model/chatReducer.ts - Chat socket
src/features/support/api/chatSocket.ts
Other components
- Panel user
- NestJS API
Connections 23
- Panel user → Application entry: opens
README.md - Application entry → Protected routes: provides router
src/app/App.tsx - Protected routes → App layout: renders protected layout
src/app/router/routes.tsx - Protected routes → Session query: checks session
src/app/router/routes.tsx - Protected routes → Login form: routes to
src/app/router/routes.tsx - Protected routes → Dashboard page: routes to
src/app/router/routes.tsx - Protected routes → Parts catalogue: routes to
src/app/router/routes.tsx - Protected routes → Support page: routes to
src/app/router/routes.tsx - App layout → Sidebar navigation: renders
src/components/layout/AppLayout.tsx - Login form → Login mutations: submits through
src/features/auth/ui/LoginForm.tsx - Login mutations → Session API: calls login
src/features/auth/hooks/useLogin.ts - Session query → Session API: fetches current user
src/features/auth/api/authQueries.ts - Session API → HTTP client: requests session
src/features/auth/api/authApi.ts - Dashboard page → Dashboard query: loads data
src/pages/dashboard/DashboardPage.tsx - Dashboard page → Dashboard widgets: renders
src/pages/dashboard/DashboardPage.tsx - Dashboard query → Dashboard API: fetches
src/features/dashboard/hooks/useDashboard.ts - Dashboard API → HTTP client: requests data
src/features/dashboard/api/dashboardApi.ts - Support page → Chat interface: renders
src/pages/support/SupportPage.tsx - Chat interface → Chat controller: uses controller
- Chat controller → Chat state: updates state
src/features/support/hooks/useSupportChat.ts - Chat controller → Chat socket: uses socket
src/features/support/hooks/useSupportChat.ts - Chat socket → NestJS API: connects by WebSocket
README.md - HTTP client → NestJS API: sends REST requests
README.md