# hanifulanwar1-web/nif_store architecture

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

- Interactive diagram: https://gitdiagram.com/hanifulanwar1-web/nif_store
- Repository: https://github.com/hanifulanwar1-web/nif_store

## Overview

NIFSTORE is a browser-based clothing storefront. Shoppers browse and filter a product catalog, inspect variants and stock, add selections to a locally persisted cart, submit buyer details, then send an order through WhatsApp; order history remains on-device. The graph captures the sampled JavaScript responsibilities and the documented product pages/capabilities suggested by the file tree. README is empty, and HTML entry-point wiring and unsampled modules were not inspected, so uncertain page-to-script links are omitted.

Main entry points: [`js/cart.js`](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/cart.js) (Cart and checkout), [`js/main.js`](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js) (Product detail), [`js/products.js`](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/products.js) (Catalog data), [`index.html`](https://github.com/hanifulanwar1-web/nif_store/blob/main/index.html) (Home page)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_catalog["Product discovery"]
  node_catalog_data[("Catalog data<br/>[products.js]")]
  node_browse_ui["Browse and filters<br/>[main.js]"]
  node_product_detail["Product detail<br/>[main.js]"]
end

subgraph group_commerce["Cart and ordering"]
  node_cart_logic["Cart and checkout<br/>[cart.js]"]
  node_cart_store[("Cart and orders<br/>[cart.js]")]
  node_order_history["Order history<br/>[main.js]"]
end

subgraph group_storefront["Storefront experience"]
  node_shared_ui["Shared interface<br/>[main.js]"]
  node_home_page["Home page<br/>[index.html]"]
  node_category_page["Category page<br/>[kategori.html]"]
  node_cart_page["Cart page<br/>[keranjang.html]"]
  node_detail_page["Detail page<br/>[detail-produk.html]"]
  node_history_page["History page<br/>[riwayat.html]"]
end

subgraph group_information["Store information"]
  node_info_pages["Store information<br/>[tentang.html]"]
  node_contact_page["Contact page<br/>[kontak.html]"]
  node_privacy_page["Privacy policy"]
  node_size_page["Size guide<br/>[ukuran.html]"]
  node_manual_page["Store manual<br/>[manual-book.html]"]
end

node_shopper(("Shopper"))
node_whatsapp(("WhatsApp seller"))

node_shopper -->|"browses"| node_browse_ui
node_browse_ui -->|"filters"| node_catalog_data
node_shopper -->|"views"| node_product_detail
node_product_detail -->|"looks up"| node_catalog_data
node_product_detail -->|"adds item"| node_cart_logic
node_cart_logic -->|"checks stock"| node_catalog_data
node_cart_logic -->|"persists"| node_cart_store
node_shopper -->|"checks out"| node_cart_logic
node_cart_logic -->|"opens order chat"| node_whatsapp
node_cart_logic -->|"saves order"| node_order_history
node_order_history -->|"reads history"| node_cart_store
node_shopper -->|"uses"| node_shared_ui
node_home_page -.->|"hosts"| node_browse_ui
node_category_page -.->|"hosts"| node_browse_ui
node_detail_page -.->|"hosts"| node_product_detail
node_cart_page -.->|"hosts"| node_cart_logic
node_history_page -.->|"hosts"| node_order_history

click node_catalog_data "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/products.js"
click node_browse_ui "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js"
click node_product_detail "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js"
click node_cart_logic "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/cart.js"
click node_cart_store "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/cart.js"
click node_order_history "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js"
click node_shared_ui "https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js"
click node_home_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/index.html"
click node_category_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/kategori.html"
click node_cart_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/keranjang.html"
click node_detail_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/detail-produk.html"
click node_history_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/riwayat.html"
click node_info_pages "https://github.com/hanifulanwar1-web/nif_store/blob/main/tentang.html"
click node_contact_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/kontak.html"
click node_privacy_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/kebijakan-privasi.html"
click node_size_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/ukuran.html"
click node_manual_page "https://github.com/hanifulanwar1-web/nif_store/blob/main/manual-book.html"

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_catalog_data,node_browse_ui,node_product_detail toneBlue
class node_cart_logic,node_cart_store,node_order_history toneAmber
class node_shared_ui,node_home_page,node_category_page,node_cart_page,node_detail_page,node_history_page toneMint
class node_info_pages,node_contact_page,node_privacy_page,node_size_page,node_manual_page toneRose
class node_shopper,node_whatsapp toneIndigo
```

## Components

### Product discovery

- [Catalog data](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/products.js): `js/products.js`
- [Browse and filters](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js): `js/main.js`
- [Product detail](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js): `js/main.js`

### Cart and ordering

- [Cart and checkout](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/cart.js): `js/cart.js`
- [Cart and orders](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/cart.js): `js/cart.js`
- [Order history](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js): `js/main.js`

### Storefront experience

- [Shared interface](https://github.com/hanifulanwar1-web/nif_store/blob/main/js/main.js): `js/main.js`
- [Home page](https://github.com/hanifulanwar1-web/nif_store/blob/main/index.html): `index.html`
- [Category page](https://github.com/hanifulanwar1-web/nif_store/blob/main/kategori.html): `kategori.html`
- [Cart page](https://github.com/hanifulanwar1-web/nif_store/blob/main/keranjang.html): `keranjang.html`
- [Detail page](https://github.com/hanifulanwar1-web/nif_store/blob/main/detail-produk.html): `detail-produk.html`
- [History page](https://github.com/hanifulanwar1-web/nif_store/blob/main/riwayat.html): `riwayat.html`

### Store information

- [Store information](https://github.com/hanifulanwar1-web/nif_store/blob/main/tentang.html): `tentang.html`
- [Contact page](https://github.com/hanifulanwar1-web/nif_store/blob/main/kontak.html): `kontak.html`
- [Privacy policy](https://github.com/hanifulanwar1-web/nif_store/blob/main/kebijakan-privasi.html): `kebijakan-privasi.html`
- [Size guide](https://github.com/hanifulanwar1-web/nif_store/blob/main/ukuran.html): `ukuran.html`
- [Store manual](https://github.com/hanifulanwar1-web/nif_store/blob/main/manual-book.html): `manual-book.html`

### Other components

- **Shopper**
- **WhatsApp seller**

## Connections

- Shopper → Browse and filters: browses (evidence: `js/main.js`)
- Browse and filters → Catalog data: filters (evidence: `js/main.js`)
- Shopper → Product detail: views (evidence: `js/main.js`)
- Product detail → Catalog data: looks up (evidence: `js/main.js`)
- Product detail → Cart and checkout: adds item (evidence: `js/main.js`)
- Cart and checkout → Catalog data: checks stock (evidence: `js/cart.js`)
- Cart and checkout → Cart and orders: persists (evidence: `js/cart.js`)
- Shopper → Cart and checkout: checks out (evidence: `js/cart.js`)
- Cart and checkout → WhatsApp seller: opens order chat (evidence: `js/cart.js`)
- Cart and checkout → Order history: saves order (evidence: `js/cart.js`)
- Order history → Cart and orders: reads history (evidence: `js/main.js`)
- Shopper → Shared interface: uses (evidence: `js/main.js`)
- Home page → Browse and filters: hosts
- Category page → Browse and filters: hosts
- Detail page → Product detail: hosts
- Cart page → Cart and checkout: hosts
- History page → Order history: hosts
