# macvanthanh123/project-web architecture

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

- Interactive diagram: https://gitdiagram.com/macvanthanh123/project-web
- Repository: https://github.com/macvanthanh123/project-web

## Overview

##### Project type and purpose
- Static, multi-page website for travel/tourism content
- All content (HTML, CSS, JS, images, fonts) is served from a web server or CDN
- No server-side application logic, database, or API

##### File structure
Top-level “html” folder contains four asset groups:
– html/ (root HTML files: home_page.html, gioi_thieu.html, various tour_*.html pages)
– html/css/ (all .css stylesheets per page)
– html/JavaScript/ (custom JS: tour_mien_bac.js)
– html/img/ (subfolders of images for each section)
– html/fontawesome copy/ (locally hosted FontAwesome assets: CSS, JS, fonts)

##### Main components
A. User’s Web Browser (Client)
B. Network / CDN / Static Web Server
C. Static Asset Groups on the Server
1. HTML Pages
2. Stylesheets (CSS)
3. JavaScript (JS)
4. Images (PNG/JPG)

##### Relationships and data flows
- Browser → HTTP GET “index.html” (or another page) → Server responds with HTML
- Browser parses HTML and issues concurrent HTTP GETs for CSS, JS, images, fonts
- CSS files apply styling; CSS may reference image files (backgrounds) and FontAwesome fonts
- JS may enhance interactivity (e.g., tour_mien_bac.js controls a specific page)

##### Architectural patterns / design principles
- Separation of concerns: HTML (structure) / CSS (presentation) / JS (behavior)
- Asset grouping by type for caching and easier maintenance
- Local hosting of third-party libraries (FontAwesome) to avoid external dependencies
- Static hosting on a CDN/Web server for speed and simplicity

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Components
    Browser["User's Web Browser"]:::browser
    Server["Static Server / CDN"]:::server

    %% Asset Groups within Server
    subgraph "HTML Files"
        HTML1["home_page.html"]:::html
        HTML2["gioi_thieu.html"]:::html
        HTML3["lien_he.html"]:::html
        HTML4["tin_tuc.html"]:::html
        HTML5["tour_*.html"]:::html
    end

    subgraph "CSS Files"
        CSS1["home_p.css"]:::css
        CSS2["gioi_thieu.css"]:::css
        CSS3["lien_he.css"]:::css
        CSS4["tin_tuc.css"]:::css
        CSS5["tour_mien_bac.css"]:::css
    end

    subgraph "JS Files"
        JS1["tour_mien_bac.js"]:::js
    end

    subgraph "Image Files"
        IMG1["img/home_p/"]:::img
        IMG2["img/gioi_thieu/"]:::img
        IMG3["img/tour_mien_bac/"]:::img
        IMG4["img/other_tours/"]:::img
    end

    subgraph "Fonts & Icons"
        FA_CSS["css/"]:::fonts
        FA_JS["js/"]:::fonts
        FA_WF["webfonts/"]:::fonts
        FA_SCSS["scss/"]:::fonts
        FA_LESS["less/"]:::fonts
        FA_META["metadata/"]:::fonts
        FA_SVGS["svgs/"]:::fonts
    end

    %% Relationships
    Browser -->|"GET *.html"| Server
    Server -->|"200 OK + HTML"| Browser

    Browser -->|"GET *.css"| CSS1
    Browser -->|"GET *.js"| JS1
    Browser -->|"GET *.png, *.jpg"| IMG1
    Browser -->|"GET *.woff2"| FA_WF

    %% Click Events
    click HTML1 "https://github.com/macvanthanh123/project-web/blob/main/html/home_page.html"
    click HTML2 "https://github.com/macvanthanh123/project-web/blob/main/html/gioi_thieu.html"
    click HTML3 "https://github.com/macvanthanh123/project-web/blob/main/html/lien_he.html"
    click HTML4 "https://github.com/macvanthanh123/project-web/blob/main/html/tin_tuc.html"
    click HTML5 "https://github.com/macvanthanh123/project-web/blob/main/html/tour_*.html"
    click CSS1 "https://github.com/macvanthanh123/project-web/blob/main/html/css/home_p.css"
    click CSS2 "https://github.com/macvanthanh123/project-web/blob/main/html/css/gioi_thieu.css"
    click CSS3 "https://github.com/macvanthanh123/project-web/blob/main/html/css/lien_he.css"
    click CSS4 "https://github.com/macvanthanh123/project-web/blob/main/html/css/tin_tuc.css"
    click CSS5 "https://github.com/macvanthanh123/project-web/blob/main/html/css/tour_mien_bac.css"
    click JS1 "https://github.com/macvanthanh123/project-web/blob/main/html/JavaScript/tour_mien_bac.js"
    click IMG1 "https://github.com/macvanthanh123/project-web/tree/main/html/img/home_p/"
    click IMG2 "https://github.com/macvanthanh123/project-web/tree/main/html/img/gioi_thieu/"
    click IMG3 "https://github.com/macvanthanh123/project-web/tree/main/html/img/tour_mien_bac/"
    click FA_CSS "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/css/"
    click FA_JS "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/js/"
    click FA_WF "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/webfonts/"
    click FA_SCSS "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/scss/"
    click FA_LESS "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/less/"
    click FA_META "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/metadata/"
    click FA_SVGS "https://github.com/macvanthanh123/project-web/tree/main/html/fontawesome copy/svgs/"

    %% Styles
    classDef browser fill:#f0f0f0,stroke:#333,stroke-width:1px
    classDef server fill:#f8f8f8,stroke:#333,stroke-width:1px
    classDef html fill:#ADD8E6,stroke:#0066cc,stroke-width:1px
    classDef css fill:#90EE90,stroke:#228B22,stroke-width:1px
    classDef js fill:#FFA500,stroke:#cc8400,stroke-width:1px
    classDef img fill:#FFFFE0,stroke:#CCCC00,stroke-width:1px
    classDef fonts fill:#D8BFD8,stroke:#9370DB,stroke-width:1px
```
