How amineamor254/shop-gaming-demo works
This is a Next.js gaming-PC storefront template. The main customer workflow is to browse and filter the catalog or configure a PC, add items to a shared cart, then review shipping, tax, and promo totals in the checkout demo. Separate routes provide account and legal UI, while the home page also presents offers, blog, and contact sections. The cart uses browser storage; README notes that payments, order creation, authentication, and some forms are simulated. Relationships below rely on the README and supplied source-index references; unsampled implementation details are not assumed.
Main entry points: app/page.tsx Home Route · CartContext.tsx Cart State · Sections/page.tsx Product Catalog · Configurator/page.tsx PC Configurator
Components 26
Storefront
- Home Route
app/page.tsx - Hero Section
components/Hero/page.tsx - Product Catalog
components/Sections/page.tsx - Shop Filter
components/Shop/shop-filter.ts - PC Configurator
components/Configurator/page.tsx - Contact UI
components/Contact/page.tsx - Site Header
components/Header/page.tsx - Root Layout
app/layout.tsx
Cart And Checkout
- Add To Cart
components/Cart/AddToCartButton.tsx - Cart State
components/Cart/CartContext.tsx - Cart Page
components/Cart/page.tsx - Checkout Demo
components/Checkout/page.tsx
Content And Account
- Blog Preview
components/Blog/page.tsx - Offers
components/Offers/page.tsx - Login Route
app/login/page.tsx - Account UI
components/Auth/page.tsx - Legal Route
app/legal/[slug]/page.tsx - Legal Content UI
components/Legal/LegalPage.tsx - Article Route
app/blog/[slug]/page.tsx
Catalog And Settings
- Product Data
data/products.ts - Configurator Data
data/configurator.ts - Promo Data
data/promos.ts - Brand Settings
config/site.ts - Post Data
data/posts.ts - Legal Text
components/Legal/legal-content.ts
Other components
- Shopper
Connections 29
- Shopper → Home Route: visits
README.md - Home Route → Hero Section: renders
app/page.tsx - Home Route → Product Catalog: renders
app/page.tsx - Home Route → PC Configurator: renders
app/page.tsx - Home Route → Blog Preview: renders
app/page.tsx - Home Route → Offers: renders
app/page.tsx - Home Route → Contact UI: renders
app/page.tsx - Root Layout → Site Header: renders
app/layout.tsx - Root Layout → Cart State: provides
app/layout.tsx - Site Header → Cart State: reads count
components/Header/page.tsx - Site Header → Shop Filter: requests category
components/Header/page.tsx - Product Catalog → Shop Filter: consumes request
components/Sections/page.tsx - Product Catalog → Product Data: reads
components/Sections/page.tsx - Product Catalog → Add To Cart: renders
components/Sections/page.tsx - Hero Section → Add To Cart: renders
components/Hero/page.tsx - Add To Cart → Cart State: adds item
components/Cart/AddToCartButton.tsx - PC Configurator → Configurator Data: reads choices
components/Configurator/page.tsx - PC Configurator → Add To Cart: renders
components/Configurator/page.tsx - Cart State → Promo Data: loads codes
components/Cart/CartContext.tsx - Cart Page → Cart State: reads and updates
components/Cart/page.tsx - Checkout Demo → Cart State: reads and clears
components/Checkout/page.tsx - Blog Preview → Post Data: reads
components/Blog/page.tsx - Article Route → Post Data: loads article data
app/blog/[slug]/page.tsx - Offers → Promo Data: uses promo data
- Login Route → Account UI: renders
app/login/page.tsx - Legal Route → Legal Content UI: renders
app/legal/[slug]/page.tsx - Legal Route → Legal Text: selects content
app/legal/[slug]/page.tsx - Legal Content UI → Legal Text: displays
components/Legal/LegalPage.tsx - PC Configurator → Brand Settings: reads settings
components/Configurator/page.tsx