How veeraharikumaran2007-sudo/arceus-gear works
ARCEUS GEAR is a gaming-hardware ecommerce store. The customer path is product discovery and detail review, cart, simulated checkout, then order history; administrators manage catalog, orders, and users, while INFY AI supports catalog questions and comparisons. The client coordinates these experiences and switches between backend and Firebase/offline catalog behavior. Edges reflect explicit imports, calls, route registration, or README capabilities; unsampled features are included without asserting unshown internal wiring.
Main entry points: App.tsx Store Experience · index.ts HTTP API · db.ts Prisma Client · api.ts API and Fallbacks
Components 31
Storefront
- Store Experience
client/src/App.tsx - Product Discovery
client/src/App.tsx - Product Details
client/src/components/ProductDetailModal.tsx - Product Cards
client/src/components/ProductCard.tsx - Cart Drawer
client/src/components/CartDrawer.tsx - Simulated Checkout
client/src/components/SimulatedCheckoutModal.tsx - Order History
client/src/components/OrderHistoryModal.tsx - Admin Dashboard
client/src/components/AdminDashboard.tsx - Sign-in
client/src/components/AuthModal.tsx - AI Assistant
client/src/components/InfyAiDrawer.tsx - Product Comparison
client/src/components/CompareModal.tsx
Client State
- Authentication State
client/src/context/AuthContext.tsx - Cart State
client/src/context/CartContext.tsx - Comparison State
client/src/context/CompareContext.tsx - API and Fallbacks
client/src/services/api.ts
Commerce API
- HTTP API
server/src/index.ts - Account Routes
server/src/routes/auth.routes.ts - Product Routes
server/src/routes/product.routes.ts - Category Routes
server/src/routes/category.routes.ts - Order Routes
server/src/routes/order.routes.ts - Admin Routes
server/src/routes/admin.routes.ts - JWT Access Control
server/src/middleware/auth.ts
Catalog and Persistence
- Firebase Services
client/src/firebase/config.ts - Embedded Catalog
client/src/data/catalog.ts - Prisma Client
server/src/db.ts - SQLite Database
AI Assistance
- INFY AI and Compare
server/src/routes/ai.routes.ts - Gemini API
- OpenRouter API
Other components
- Shopper
- Administrator
Connections 48
- Shopper → Store Experience: browses
client/src/App.tsx - Administrator → Store Experience: opens
client/src/App.tsx - Store Experience → Product Discovery: renders
client/src/App.tsx - Store Experience → Product Cards: renders
client/src/App.tsx - Store Experience → Product Details: renders
client/src/App.tsx - Store Experience → Cart Drawer: renders
client/src/App.tsx - Store Experience → Simulated Checkout: renders
client/src/App.tsx - Store Experience → Order History: renders
client/src/App.tsx - Store Experience → Admin Dashboard: renders
client/src/App.tsx - Store Experience → AI Assistant: renders
- Store Experience → Product Comparison: renders
client/src/App.tsx - Store Experience → Sign-in: renders
client/src/App.tsx - Product Cards → Cart State: adds items
client/src/components/ProductCard.tsx - Product Cards → Comparison State: selects products
client/src/components/ProductCard.tsx - Product Details → Cart State: adds items
client/src/components/ProductDetailModal.tsx - Product Details → Comparison State: selects products
client/src/components/ProductDetailModal.tsx - Cart Drawer → Cart State: uses
client/src/components/CartDrawer.tsx - Simulated Checkout → Cart State: reads cart
client/src/components/SimulatedCheckoutModal.tsx - Simulated Checkout → API and Fallbacks: submits order
client/src/components/SimulatedCheckoutModal.tsx - Order History → Firebase Services: loads orders
client/src/components/OrderHistoryModal.tsx - Admin Dashboard → API and Fallbacks: manages store
client/src/components/AdminDashboard.tsx - Sign-in → Authentication State: authenticates
client/src/components/AuthModal.tsx - Authentication State → API and Fallbacks: calls account API
client/src/context/AuthContext.tsx - Authentication State → Firebase Services: uses Google sign-in
client/src/context/AuthContext.tsx - API and Fallbacks → Firebase Services: loads catalog and saves orders
client/src/services/api.ts - API and Fallbacks → Embedded Catalog: falls back to
client/src/services/api.ts - API and Fallbacks → HTTP API: requests API
client/src/services/api.ts - HTTP API → Account Routes: registers
server/src/index.ts - HTTP API → Product Routes: registers
server/src/index.ts - HTTP API → Category Routes: registers
server/src/index.ts - HTTP API → Order Routes: registers
server/src/index.ts - HTTP API → Admin Routes: registers
server/src/index.ts - HTTP API → INFY AI and Compare: registers
server/src/index.ts - Account Routes → JWT Access Control: uses
server/src/routes/auth.routes.ts - Product Routes → JWT Access Control: uses
server/src/routes/product.routes.ts - Category Routes → JWT Access Control: uses
server/src/routes/category.routes.ts - Order Routes → JWT Access Control: uses
server/src/routes/order.routes.ts - Admin Routes → JWT Access Control: uses
server/src/routes/admin.routes.ts - JWT Access Control → Prisma Client: checks users
server/src/middleware/auth.ts - Account Routes → Prisma Client: queries
server/src/routes/auth.routes.ts - Product Routes → Prisma Client: queries
server/src/routes/product.routes.ts - Category Routes → Prisma Client: queries
server/src/routes/category.routes.ts - Order Routes → Prisma Client: queries
server/src/routes/order.routes.ts - Admin Routes → Prisma Client: queries
server/src/routes/admin.routes.ts - INFY AI and Compare → Prisma Client: reads catalog
server/src/routes/ai.routes.ts - Prisma Client → SQLite Database: persists data
- AI Assistant → API and Fallbacks: asks questions
- Product Comparison → Comparison State: reads selection
client/src/components/CompareModal.tsx