Is an Food Order Tracking App. The owner register Restaurants, and Customer order…
- User
Is an Food Order Tracking App. The owner register Restaurants, and Customer order differents foods from each reataurant they selected. The app must work web and android. The user can view orders, traking active orders, pay online with credit card, pay by yappy.
Assistant
This is a much bigger app now — a full food ordering platform. Let me re-architect. I'll build a two-role app:
- Customer: browse restaurants → order food → pay (credit card / Yappy) → track live order → view order history
- Owner: register restaurants, manage menus, accept & advance orders
It'll be mobile-first responsive (works on web + Android). Let me first check the config, then clean up the old files.
Config confirmed: React 19, Tailwind v4, strict TS with
noUnusedLocals. I'll use type-only imports. Let me remove the old files and create the foundation (types, format utils, icon set).The remaining errors are just from the old
App.tsxreferencing deleted files — I'll replace it last. Let me create the order-lifecycle helpers and the seed data (Panamanian restaurants + menus).Now the central store (state + reducer + localStorage persistence) and shared UI components (Button, Modal, inputs, QR, etc.).
Now the three customer screens: restaurant browsing/menu, checkout (card + Yappy), and orders/tracking. Creating them together.
Now the checkout screen with credit-card and Yappy payment flows.
Now the orders list and live tracking screen (with auto-advancing timeline).
One unused variable to clean up in
TrackScreen. Let me remove it.Now the customer shell (header, bottom nav, routing, cart badge) that ties the screens together.
Let me fix a breakpoint issue —
xs:isn't a default Tailwind breakpoint, so the "Owner" label would stay hidden. I'll make it always visible.Now the owner side. First, restaurant management (register restaurants + menu editor with availability toggles).
Now the owner shell — dashboard with stats, plus an orders manager where the owner accepts and advances orders.
The cancel condition has a redundant comparison. Let me simplify it.
Finally, the root
Appwires the store provider and switches between customer/owner roles. I'll also update the page title.Let me check the current
index.htmltitle and update it.Now let me build to confirm everything compiles.
Build succeeded — 44 modules, no errors. The full food ordering platform is complete.
What I built: FoodTrack 🍽️
A two-role food-ordering platform that works as a responsive web app (mobile-app feel for customers, full dashboard for owners — so it runs on both web and Android, and all data persists in
localStorage).👤 Customer experience (mobile-first, centered app)
- Browse restaurants with search, cuisine filters, and a "Featured today" carousel — seeded with Panamanian spots (Sazón Panamá, Pizza Forte, Burger District, Sushi Niwa, etc.), each with a full menu.
- Order from any restaurant; adding a dish from a different restaurant prompts a smart "start new order?" confirmation (single-restaurant cart enforced).
- Pay online with two methods:
- Credit card — live card preview, brand detection (Visa/Mastercard/Amex), auto-formatting for number/expiry, and validation.
- Yappy ⚡ — generates a QR-code payment screen with amount to confirm in-app (Panama's payment method).
- Track active orders — a live status timeline (Placed → Confirmed → Preparing → On the way → Delivered) that auto-advances in real time, with progress bar, ETA, a rider contact card, and full order recap.
- Order history with active vs. past sections.
🏪 Owner portal (desktop dashboard)
- Register restaurants via a form (name, cuisine, logo emoji, brand-color gradient, delivery time/fee, open/closed).
- Manage menus — add/edit/delete dishes, toggle availability per item, edit or delete restaurants.
- Dashboard with stats (restaurants, total/active orders, revenue) and recent orders.
- Orders manager — filter by New/Active/Completed, and accept → prepare → send out → deliver (or cancel) each order.
Architecture
store.tsx— global state via Context + reducer, persisted to localStorage (shared between both roles).utils/order.ts— order lifecycle, status styling, timeline progression.components/— reusable UI (Button, Modal/bottom-sheet, inputs, decorative QR, icons).customer/andowner/folders for each role's screens.
The customer/owner can switch roles from either header, and the same orders flow between them — place an order as a customer, then jump to the owner portal to accept and advance it.
Files built:
src/types.ts,src/utils/format.ts,src/components/icons.tsx,src/utils/order.ts,src/seed.ts,src/store.tsx,src/components/common.tsx,src/customer/browse.tsx,src/customer/checkout.tsx,src/customer/orders.tsx,src/customer/CustomerApp.tsx,src/owner/Restaurants.tsx,src/owner/OwnerApp.tsx,src/App.tsx,index.html
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.