How komal-atif/assaanmart-fyp works
AssanMart is a grocery-shopping app with catalog browsing, cart and checkout, account/order features, voice ordering, and photo-based list scanning. The main flow is a shopper browsing or using an assisted input, then reviewing a cart and placing an order through the backend. The graph reflects documented UI and API calls; backend internals and several frontend details were not excerpted, so their internal relationships are intentionally left unspecified.
Main entry points: App.tsx App Orchestrator · orderApi.ts Order API · voiceApi.ts Voice API · VoiceAssistantModal.tsx Voice Assistant
Components 20
Shopping Experience
- Store Dashboard
frontend/src/components/StoreDashboard.tsx - Product Card
frontend/src/components/ProductCard.tsx - Product Detail
frontend/src/components/ProductDetailModal.tsx - Cart Drawer
frontend/src/components/CartDrawer.tsx - Grocery Dataset
frontend/src/data/groceryData.ts - How It Works
frontend/src/components/HowItWorks.tsx
Assisted Ordering
- Voice Assistant
frontend/src/components/VoiceAssistantModal.tsx - Voice Capture Loop
frontend/src/hooks/useVoiceLoop.ts - Voice Avatar
frontend/src/components/voice/VoiceAvatar.tsx - Grocery List Scanner
frontend/src/components/GroceryImageScannerModal.tsx
Accounts & Orders
- Checkout
frontend/src/components/CheckoutModal.tsx - Authentication
frontend/src/components/AuthModal.tsx - Order History
frontend/src/components/MyOrdersModal.tsx
Application & APIs
- App Orchestrator
frontend/src/App.tsx - Catalog API
frontend/src/services/catalogApi.ts - Order API
frontend/src/services/orderApi.ts - Voice API
frontend/src/services/voiceApi.ts - FastAPI Backend
backend/backend.py - Supabase Client
frontend/src/supabaseClient.ts
Other components
- Shopper
Connections 25
- Shopper → App Orchestrator: uses
frontend/src/App.tsx - App Orchestrator → Catalog API: loads catalog
frontend/src/App.tsx - App Orchestrator → Store Dashboard: renders
frontend/src/App.tsx - Store Dashboard → Product Card: renders
frontend/src/components/StoreDashboard.tsx - App Orchestrator → Product Detail: opens
frontend/src/App.tsx - App Orchestrator → Cart Drawer: renders
frontend/src/App.tsx - App Orchestrator → Checkout: opens
frontend/src/App.tsx - App Orchestrator → Authentication: opens
frontend/src/App.tsx - App Orchestrator → Order History: opens
frontend/src/App.tsx - Checkout → Order API: places order
frontend/src/components/CheckoutModal.tsx - Order History → Order API: fetches orders
frontend/src/components/MyOrdersModal.tsx - Authentication → Order API: saves profile
frontend/src/components/AuthModal.tsx - Authentication → Supabase Client: authenticates
frontend/src/components/AuthModal.tsx - App Orchestrator → Voice Assistant: opens
frontend/src/App.tsx - Voice Assistant → Voice Capture Loop: captures speech
frontend/src/components/VoiceAssistantModal.tsx - Voice Assistant → Voice Avatar: renders
frontend/src/components/VoiceAssistantModal.tsx - Voice Assistant → Voice API: sends voice turns
frontend/src/components/VoiceAssistantModal.tsx - Voice API → FastAPI Backend: calls voice routes
frontend/src/services/voiceApi.ts - App Orchestrator → Grocery List Scanner: opens
frontend/src/App.tsx - Grocery List Scanner → Order API: submits image
frontend/src/components/GroceryImageScannerModal.tsx - Grocery List Scanner → Voice API: uses scan voice
frontend/src/components/GroceryImageScannerModal.tsx - Order API → FastAPI Backend: calls order routes
frontend/src/services/orderApi.ts - Order API → Voice API: gets API headers
frontend/src/services/orderApi.ts - Voice API → Supabase Client: gets credentials
frontend/src/services/voiceApi.ts - App Orchestrator → How It Works: renders