How ahmed-abd-alrahman515/ecomtest works
This is a bilingual Saudi-perfume storefront built as a Next.js app, with product and category data held locally rather than a documented commerce backend. The main customer journey is to browse or search the catalog, inspect a product, add it to a locally persisted cart, and review it at checkout. Separate branches cover wishlists, store information, and customer support. The graph reflects documented imports and sampled source; checkout and other unsampled pages are represented by their paths, without inferring payment processing or fulfillment integrations.
Main entry points: cart-context.tsx Cart State · products.ts Product Data · product-detail.tsx Product Detail · header.tsx Store Header
Components 26
Store Discovery
- Home Page
app/(shop)/page.tsx - Home Sections
components/home - Catalog Pages
app/(shop)/products/page.tsx - Category Pages
app/(shop)/categories/page.tsx - Search Page
app/(shop)/search/page.tsx - Product Page
app/(shop)/product/[slug]/page.tsx - Catalog UI
components/products - Product Detail
components/products/product-detail.tsx - Product Card
components/shared/product-card.tsx
Shopping State
- Cart State
lib/cart-context.tsx - Cart Views
app/(shop)/cart/page.tsx - Cart Drawer
components/layout/cart-drawer.tsx - Checkout Page
app/(shop)/checkout/page.tsx - Wishlist Page
app/(shop)/wishlist/page.tsx - Wishlist State
lib/wishlist-context.tsx
Storefront Experience
- Shop Layout
app/(shop)/layout.tsx - Store Header
components/layout/header.tsx - Search Overlay
components/layout/search-overlay.tsx - Store Information
app/(shop)/about/page.tsx - Support Pages
app/(shop)/services/page.tsx - Contact Page
app/(shop)/contact/page.tsx
Catalog Foundation
- Product Data
data/products.ts - Category Data
data/categories.ts - Store Config
config/site.ts - Price Formatting
lib/format.ts
Other components
- Shopper
Connections 39
- Shopper → Home Page: opens
- Shopper → Catalog Pages: browses
- Shopper → Search Page: searches
- Shopper → Product Page: opens
- Shopper → Cart Views: reviews cart
- Shopper → Checkout Page: continues to
- Home Page → Home Sections: renders
app/(shop)/page.tsx - Home Sections → Product Data: reads products
components/home/best-sellers-section.tsx - Home Sections → Category Data: reads categories
components/home/categories-section.tsx - Catalog Pages → Catalog UI: renders
app/(shop)/products/page.tsx - Catalog Pages → Product Data: reads products
app/(shop)/products/page.tsx - Catalog Pages → Category Data: reads categories
app/(shop)/products/page.tsx - Category Pages → Catalog UI: renders
- Search Page → Product Data: searches
- Product Page → Product Detail: renders
- Product Detail → Product Data: reads product
components/products/product-detail.tsx - Product Detail → Cart State: adds item
components/products/product-detail.tsx - Product Detail → Wishlist State: toggles wishlist
components/products/product-detail.tsx - Product Card → Cart State: adds item
components/shared/product-card.tsx - Product Card → Wishlist State: toggles wishlist
components/shared/product-card.tsx - Product Card → Product Data: gets discount
components/shared/product-card.tsx - Product Card → Category Data: looks up category
components/shared/product-card.tsx - Cart Views → Cart State: reads and updates
app/(shop)/cart/page.tsx - Cart Views → Price Formatting: formats prices
app/(shop)/cart/page.tsx - Cart Drawer → Cart State: reads and updates
components/layout/cart-drawer.tsx - Checkout Page → Cart State: reads cart
app/(shop)/checkout/page.tsx - Wishlist Page → Wishlist State: reads wishlist
app/(shop)/wishlist/page.tsx - Wishlist Page → Product Data: looks up products
app/(shop)/wishlist/page.tsx - Wishlist Page → Cart State: adds to cart
app/(shop)/wishlist/page.tsx - Shop Layout → Store Header: renders
- Store Header → Search Overlay: opens
components/layout/header.tsx - Store Header → Cart Drawer: renders
components/layout/header.tsx - Store Header → Cart State: reads cart
components/layout/header.tsx - Store Header → Wishlist State: reads wishlist
components/layout/header.tsx - Search Overlay → Product Data: searches products
components/layout/search-overlay.tsx - Home Page → Store Config: uses branding
- Store Information → Store Config: uses branding
app/(shop)/about/page.tsx - Contact Page → Store Config: uses contact details
app/(shop)/contact/page.tsx - Product Detail → Price Formatting: formats prices
components/products/product-detail.tsx