# johanamisaela/m1p13mean-mahery-joanna-client architecture

> Architecture diagram of the GitHub repository johanamisaela/m1p13mean-mahery-joanna-client, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-12). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/johanamisaela/m1p13mean-mahery-joanna-client
- Repository: https://github.com/johanamisaela/m1p13mean-mahery-joanna-client

## Overview

This is an Angular ecommerce frontend. Users browse products and shops, inspect product variants and promotions, manage favorites and a cart, then access orders and chat; authenticated shop/admin users also manage shop operations. Routing selects feature views, which use core services to call the configured API. The graph preserves major feature areas and central services; unsampled feature internals are represented by their exact enclosing directories, and their connections are omitted where the excerpts do not establish them.

Main entry points: [`src/app/app.routes.ts`](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/app.routes.ts) (Route table), [`src/app/core/services/product.service.ts`](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/product.service.ts) (Product API), [`src/app/features/product-detail/product-detail.component.ts`](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/product-detail/product-detail.component.ts) (Product detail), [`src/app/features/home/home.component.ts`](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/home/home.component.ts) (Home & discovery)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_routing["App shell"]
  node_routes["Route table<br/>[app.routes.ts]"]
  node_layout["Main layout"]
end

subgraph group_shopping["Shopping"]
  node_home["Home &amp; discovery<br/>[home.component.ts]"]
  node_shops["Shop browsing"]
  node_product["Product detail"]
  node_reviews["Reviews &amp; ratings"]
  node_favorites["Favorites"]
  node_cartview["Cart &amp; checkout<br/>[cart.component.ts]"]
end

subgraph group_account["Account"]
  node_authview["Login &amp; signup"]
  node_profile["Profile"]
  node_orders["Orders"]
  node_chat["Messaging<br/>[chat.component.ts]"]
end

subgraph group_operations["Shop operations"]
  node_dashboard["Admin dashboard"]
  node_shopmanage["Shop management"]
end

subgraph group_services["Core services"]
  node_authsvc["Authentication<br/>[auth.service.ts]"]
  node_cartservice["Cart state &amp; API<br/>[cart.service.ts]"]
  node_productsvc["Product API<br/>[product.service.ts]"]
  node_promotion["Promotion API"]
  node_category["Category API"]
  node_shopservice["Shop API<br/>[shop.service.ts]"]
  node_orderservice["Order API<br/>[order.service.ts]"]
  node_chatservice["Chat API<br/>[chat.service.ts]"]
end

node_user(("Visitor / user"))
node_backend{{"Ecommerce API"}}

node_user -->|"navigates"| node_routes
node_routes -->|"loads shell"| node_layout
node_routes -->|"routes to"| node_home
node_routes -->|"routes to"| node_shops
node_routes -->|"routes to"| node_product
node_routes -->|"routes to"| node_dashboard
node_routes -->|"routes to"| node_profile
node_routes -->|"routes to"| node_favorites
node_routes -->|"routes to"| node_orders
node_routes -->|"routes to"| node_shopmanage
node_routes -->|"routes to"| node_cartview
node_routes -->|"routes to"| node_chat
node_routes -->|"routes to"| node_authview
node_home -->|"loads products"| node_productsvc
node_home -->|"loads categories"| node_category
node_home -->|"loads shops"| node_shopservice
node_product -->|"loads product"| node_productsvc
node_product -.->|"adds item"| node_cartservice
node_product -.->|"loads promotions"| node_promotion
node_product -.->|"renders reviews"| node_reviews
node_reviews -->|"submits reviews"| node_productsvc
node_favorites -->|"loads favorites"| node_productsvc
node_favorites -->|"loads shops"| node_shopservice
node_cartview -->|"reads cart"| node_cartservice
node_authview -.->|"authenticates"| node_authsvc
node_chat -->|"sends messages"| node_chatservice
node_chat -->|"reads identity"| node_authsvc
node_chat -->|"loads shop"| node_shopservice
node_authsvc -->|"HTTP auth"| node_backend
node_cartservice -->|"HTTP cart"| node_backend
node_productsvc -->|"HTTP products"| node_backend
node_productsvc -->|"HTTP reviews"| node_backend

click node_routes "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/app.routes.ts"
click node_layout "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/layout/main-layout/main-layout.component.ts"
click node_home "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/home/home.component.ts"
click node_shops "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/shops"
click node_product "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/product-detail/product-detail.component.ts"
click node_reviews "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/product-detail/components/product-reviews/product-reviews.component.ts"
click node_favorites "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/favorites/favorites.component.ts"
click node_cartview "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/cart/cart.component.ts"
click node_authview "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/auth"
click node_profile "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/profil/profil.component.ts"
click node_orders "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/orders/orders.component.ts"
click node_chat "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/chat/chat.component.ts"
click node_dashboard "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/dashboard"
click node_shopmanage "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/dashboard/shop"
click node_authsvc "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/auth.service.ts"
click node_cartservice "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/cart.service.ts"
click node_productsvc "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/product.service.ts"
click node_promotion "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/promotion.service.ts"
click node_category "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/category.service.ts"
click node_shopservice "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/shop.service.ts"
click node_orderservice "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/order.service.ts"
click node_chatservice "https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/chat.service.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_routes,node_layout,node_user toneBlue
class node_home,node_shops,node_product,node_reviews,node_favorites,node_cartview toneAmber
class node_authview,node_profile,node_orders,node_chat,node_backend toneMint
class node_dashboard,node_shopmanage toneRose
class node_authsvc,node_cartservice,node_productsvc,node_promotion,node_category,node_shopservice,node_orderservice,node_chatservice toneIndigo
```

## Components

### App shell

- [Route table](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/app.routes.ts): `src/app/app.routes.ts`
- [Main layout](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/layout/main-layout/main-layout.component.ts): `src/app/core/layout/main-layout/main-layout.component.ts`

### Shopping

- [Home & discovery](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/home/home.component.ts): `src/app/features/home/home.component.ts`
- [Shop browsing](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/shops): `src/app/features/shops`
- [Product detail](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/product-detail/product-detail.component.ts): `src/app/features/product-detail/product-detail.component.ts`
- [Reviews & ratings](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/product-detail/components/product-reviews/product-reviews.component.ts): `src/app/features/product-detail/components/product-reviews/product-reviews.component.ts`
- [Favorites](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/favorites/favorites.component.ts): `src/app/features/favorites/favorites.component.ts`
- [Cart & checkout](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/cart/cart.component.ts): `src/app/features/cart/cart.component.ts`

### Account

- [Login & signup](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/auth): `src/app/features/auth`
- [Profile](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/profil/profil.component.ts): `src/app/features/profil/profil.component.ts`
- [Orders](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/orders/orders.component.ts): `src/app/features/orders/orders.component.ts`
- [Messaging](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/features/chat/chat.component.ts): `src/app/features/chat/chat.component.ts`

### Shop operations

- [Admin dashboard](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/dashboard): `src/app/features/dashboard`
- [Shop management](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/tree/main/src/app/features/dashboard/shop): `src/app/features/dashboard/shop`

### Core services

- [Authentication](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/auth.service.ts): `src/app/core/services/auth.service.ts`
- [Cart state & API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/cart.service.ts): `src/app/core/services/cart.service.ts`
- [Product API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/product.service.ts): `src/app/core/services/product.service.ts`
- [Promotion API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/promotion.service.ts): `src/app/core/services/promotion.service.ts`
- [Category API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/category.service.ts): `src/app/core/services/category.service.ts`
- [Shop API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/shop.service.ts): `src/app/core/services/shop.service.ts`
- [Order API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/order.service.ts): `src/app/core/services/order.service.ts`
- [Chat API](https://github.com/johanamisaela/m1p13mean-mahery-joanna-client/blob/main/src/app/core/services/chat.service.ts): `src/app/core/services/chat.service.ts`

### Other components

- **Visitor / user**
- **Ecommerce API**

## Connections

- Visitor / user → Route table: navigates (evidence: `src/app/app.routes.ts`)
- Route table → Main layout: loads shell (evidence: `src/app/app.routes.ts`)
- Route table → Home & discovery: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Shop browsing: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Product detail: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Admin dashboard: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Profile: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Favorites: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Orders: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Shop management: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Cart & checkout: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Messaging: routes to (evidence: `src/app/app.routes.ts`)
- Route table → Login & signup: routes to (evidence: `src/app/app.routes.ts`)
- Home & discovery → Product API: loads products (evidence: `src/app/features/home/home.component.ts`)
- Home & discovery → Category API: loads categories (evidence: `src/app/features/home/home.component.ts`)
- Home & discovery → Shop API: loads shops (evidence: `src/app/features/home/home.component.ts`)
- Product detail → Product API: loads product (evidence: `src/app/features/product-detail/product-detail.component.ts`)
- Product detail → Cart state & API: adds item (evidence: `src/app/features/product-detail/product-detail.component.ts`)
- Product detail → Promotion API: loads promotions (evidence: `src/app/features/product-detail/product-detail.component.ts`)
- Product detail → Reviews & ratings: renders reviews (evidence: `src/app/features/product-detail/product-detail.component.ts`)
- Reviews & ratings → Product API: submits reviews (evidence: `src/app/features/product-detail/components/product-reviews/product-reviews.component.ts`)
- Favorites → Product API: loads favorites (evidence: `src/app/features/favorites/favorites.component.ts`)
- Favorites → Shop API: loads shops (evidence: `src/app/features/favorites/favorites.component.ts`)
- Cart & checkout → Cart state & API: reads cart (evidence: `src/app/features/cart/cart.component.ts`)
- Login & signup → Authentication: authenticates (evidence: `src/app/features/auth/signup/signup.component.ts`)
- Messaging → Chat API: sends messages (evidence: `src/app/features/chat/chat.component.ts`)
- Messaging → Authentication: reads identity (evidence: `src/app/features/chat/chat.component.ts`)
- Messaging → Shop API: loads shop (evidence: `src/app/features/chat/chat.component.ts`)
- Authentication → Ecommerce API: HTTP auth (evidence: `src/app/core/services/auth.service.ts`)
- Cart state & API → Ecommerce API: HTTP cart (evidence: `src/app/core/services/cart.service.ts`)
- Product API → Ecommerce API: HTTP products (evidence: `src/app/core/services/product.service.ts`)
- Product API → Ecommerce API: HTTP reviews (evidence: `src/app/core/services/product.service.ts`)
