# bonolo2s/portfolio-website-2 architecture

> Architecture diagram of the GitHub repository bonolo2s/portfolio-website-2, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-04-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bonolo2s/portfolio-website-2
- Repository: https://github.com/bonolo2s/portfolio-website-2

## Overview

##### Project type and purpose
- This is a static portfolio website (“Portfolio-website-2”) whose goal is to showcase a personal CV, client testimonials, and other assets. There is no backend or database—just HTML, CSS, JavaScript, PDF files, and static asset folders.

##### File structure
- Top-level files:
- index.html (entry point)
- main.js (client-side behavior)
- styles.css (presentation)
- Bonolo Selowa Cv.pdf & Curricullum vitae.pdf (downloadable resumes)
- README.md (project title)
- Directories:
- Client testimonials (contains gift.html for individual testimonial page)
- There are no server-side scripts, configuration files, or build tools—this is purely front-end.

##### README
- Contains only the project name. No extra architecture info or dependencies to document.

##### Components
a. User’s Web Browser
- Renders index.html, loads CSS and JS, displays PDFs and testimonial pages.
b. Static Web Server or Hosting Service
- Serves index.html, main.js, styles.css, PDFs, and files in assets/ and Client testimonials/.
- Could be GitHub Pages, Netlify, S3+CloudFront, or any CDN.
c. CDN or Asset Delivery (optional)
d. External Services (optional)

##### Relationships and data flows
- Browser requests → Web Server: “GET styles.css, main.js, /assets/*, /Client testimonials/gift.html, PDFs”
- If using CDN: Web Server or Browser → CDN: “fetch images/fonts”
- Browser renders and displays content to the user.

##### Architectural patterns and design principles
- Static site architecture (no runtime server logic).
- Separation of concerns: HTML for structure, CSS for styling, JavaScript for interactivity, PDFs and HTML in separate folders for content distribution.
- Keep assets in a dedicated folder to simplify caching and CDN distribution.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Client-side Component
    subgraph "Client-Side"
        Browser["User's Web Browser"]:::client
    end

    %% Hosting and Infrastructure
    subgraph "Hosting Infrastructure"
        StaticHost["Static Web Server / Hosting Service"]:::infra
        CDN["CDN / Asset Delivery"]:::infra
    end

    %% Static Content
    subgraph "Static Content" 
        Entry["index.html"]:::content
        CSS["styles.css"]:::content
        JS["main.js"]:::content
        AssetsFolder["assets/"]:::content
        TestimonialsFolder["Client testimonials/"]:::content
        Gift["gift.html"]:::content
        PDF1["Bonolo Selowa Cv.pdf"]:::content
        PDF2["Curricullum vitae.pdf"]:::content
        Readme["README.md"]:::content
    end

    %% Data Flows
    Browser -->|"GET index.html"| StaticHost
    Browser -->|"GET styles.css"| StaticHost
    Browser -->|"GET main.js"| StaticHost
    Browser -->|"GET assets/*"| CDN
    Browser -->|"GET Client testimonials/*"| StaticHost
    Browser -->|"GET gift.html"| StaticHost
    Browser -->|"GET PDFs"| StaticHost

    CDN -->|"Fetch cached assets"| AssetsFolder
    StaticHost -->|"Serves static files"| Entry
    StaticHost -->|"Serves static files"| CSS
    StaticHost -->|"Serves static files"| JS
    StaticHost -->|"Serves static files"| AssetsFolder
    StaticHost -->|"Serves static files"| TestimonialsFolder
    StaticHost -->|"Serves static files"| Gift
    StaticHost -->|"Serves static files"| PDF1
    StaticHost -->|"Serves static files"| PDF2
    StaticHost -->|"Serves static files"| Readme

    %% Click Events
    click Entry "https://github.com/bonolo2s/portfolio-website-2/blob/main/index.html"
    click CSS "https://github.com/bonolo2s/portfolio-website-2/blob/main/styles.css"
    click JS "https://github.com/bonolo2s/portfolio-website-2/blob/main/main.js"
    click AssetsFolder "https://github.com/bonolo2s/portfolio-website-2/tree/main/assets/"
    click TestimonialsFolder "https://github.com/bonolo2s/portfolio-website-2/tree/main/Client testimonials/"
    click Gift "https://github.com/bonolo2s/portfolio-website-2/blob/main/Client testimonials/gift.html"
    click PDF1 "https://github.com/bonolo2s/portfolio-website-2/blob/main/Bonolo Selowa Cv.pdf"
    click PDF2 "https://github.com/bonolo2s/portfolio-website-2/blob/main/Bonolo Selowa Curricullum vitae.pdf"
    click Readme "https://github.com/bonolo2s/portfolio-website-2/blob/main/README.md"

    %% Styles
    classDef client fill:#8FD3F4,stroke:#333,stroke-width:1px
    classDef infra fill:#F4D38F,stroke:#333,stroke-width:1px
    classDef content fill:#D3F48F,stroke:#333,stroke-width:1px
```
