How terboubomar/talab works
Talab is a restaurant ordering and operations platform: customers select a branch and order type, browse a menu, build a cart, and check out; staff manage branches, catalog, orders, payments, and reporting. A separate driver app supports delivery work. The graph also preserves the documented-in-tree integration workspaces and serverless functions. Relationship evidence is limited to the README and SOURCE INDEX references; unsampled modules are represented by their exact paths, but uncertain links are omitted.
Main entry points: storefront.ts Storefront data · checkout.tsx Checkout · _staffShell.admin.orders.tsx Admin routes · index.tsx Storefront
Components 24
Customer ordering
- Storefront
src/routes/index.tsx - Menu browsing
src/routes/menu.tsx - Cart state
src/lib/cart.ts - Checkout
src/routes/checkout.tsx - Payment form
src/components/moyasar-payment-form.tsx - Customer account
src/routes/account.tsx
Staff operations
- Admin routes
src/routes/_staffShell.admin.orders.tsx - Branch operations
src/lib/branch-operations.ts - Catalog management
src/lib/catalog.ts - Order operations
src/lib/order-detail.ts - Reports
src/lib/report-center.ts - Marketing tools
src/routes/_staffShell.admin.coupons.tsx
Shared platform
- Application router
src/router.tsx - Storefront data
src/lib/storefront.ts - Menu data
src/lib/menu.ts - Supabase client
src/lib/supabase.ts - Supabase database
Integrations
- Payment functions
supabase/functions/moyasar-webhook/index.ts - Foodics functions
supabase/functions/foodics-order-push/index.ts - Loyverse workspace
src/components/admin/LoyverseIntegrationWorkspace.tsx
Driver app
- Driver app
apps/driver/App.tsx - Driver API
apps/driver/src/lib/api.ts - Driver Supabase
apps/driver/src/lib/supabase.ts
Other components
- Customer
Connections 19
- Customer → Storefront: opens
- Application router → Storefront: routes to
src/router.tsx - Application router → Admin routes: routes to
src/routeTree.gen.ts - Storefront → Storefront data: loads context
- Menu browsing → Menu data: loads menu
- Checkout → Storefront data: reads selection
src/routes/checkout.tsx - Checkout → Cart state: reads cart
src/routes/checkout.tsx - Checkout → Menu data: formats items
src/routes/checkout.tsx - Checkout → Payment form: renders
src/routes/checkout.tsx - Customer account → Storefront data: uses data
- Admin routes → Branch operations: uses operations
- Admin routes → Reports: loads reports
- Admin routes → Marketing tools: routes to
src/routeTree.gen.ts - Marketing tools → Storefront data: uses settings
- Storefront data → Supabase client: queries
src/lib/storefront.ts - Menu data → Supabase client: queries
src/lib/menu.ts - Supabase client → Supabase database: connects
src/lib/supabase.ts - Driver app → Driver API: requests data
apps/driver/App.tsx - Driver API → Driver Supabase: uses client
apps/driver/src/lib/api.ts