# criscuba/personal-website architecture

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

- Interactive diagram: https://gitdiagram.com/criscuba/personal-website
- Repository: https://github.com/criscuba/personal-website

## Overview

##### Project Type and Purpose
- This is a personal portfolio website for Cristian Gonzalez. It’s built using fundamental web technologies (HTML5, CSS3, and Vanilla JavaScript) and includes several sections such as a main landing page, an admin section, a backup version of the site, and some server-side functionality.
- The README highlights that the aim is to present professional and project information with a modern, responsive, and minimalistic design. There is also a mention of a contact form and dynamically presented effects.

##### File Structure
- Top-Level Files & Folders:
- index.html and script.js indicate the primary (public) website.
- The “admin” folder contains a separate admin area (admin.html, admin.js, admin.css) which could be used for managing or updating content.
- The “backup” folder appears to provide an alternative version of the website (perhaps a fallback strategy).
- The “data” folder holds JSON data (e.g., contact-messages.json) suggesting that form submissions or contact information might be stored or processed there.
- The “server” folder includes a Node.js-based backend (server.js and package.json) that might serve content, handle API requests, or support server-side logic.
- The “src” folder contains assets (like the CV PDF) and extra styling (styles.css) implying a modularized asset management approach.
- The .github folder with workflows alerts you to automation for deployment (likely generating GitHub Pages using Jekyll).

##### Final Advice
- That every component (frontend, admin, server, data, assets, CI/CD) is clearly represented with identifiable labels.

## Diagram (Mermaid)

```mermaid
flowchart TD
    U["User"]:::user

    subgraph "Frontend Layer"
        PW["Public Website"]:::frontend
        AI["Admin Interface"]:::admin
        BS["Backup Site"]:::backup
    end

    subgraph "Backend & Data"
        SB["Server/Backend"]:::backend
        DM["Data Management"]:::database
    end

    subgraph "Assets & Deployment"
        AS["Assets & Static Resources"]:::assets
        CI["CI/CD Pipeline"]:::cicd
    end

    U -->|"interacts"| PW
    U -->|"interacts"| AI
    U -->|"interacts"| BS

    PW -->|"sendsFormData"| SB
    AI -->|"adminActions"| SB
    SB -->|"readsWrites"| DM

    PW -->|"loadsAssets"| AS

    CI -->|"deploysUpdates"| PW
    CI -->|"deploysUpdates"| AI
    CI -->|"deploysUpdates"| BS
    CI -->|"deploysAssets"| AS

    click PW "https://github.com/criscuba/personal-website/blob/main/index.html"
    click AI "https://github.com/criscuba/personal-website/blob/main/admin/index.html"
    click BS "https://github.com/criscuba/personal-website/blob/main/backup/index.html"
    click SB "https://github.com/criscuba/personal-website/blob/main/server/server.js"
    click DM "https://github.com/criscuba/personal-website/blob/main/data/contact-messages.json"
    click AS "https://github.com/criscuba/personal-website/tree/main/src/assets"
    click CI "https://github.com/criscuba/personal-website/blob/main/.github/workflows/jekyll-gh-pages.yml"

    classDef frontend fill:#a2d2ff,stroke:#0e4d92,stroke-width:2px;
    classDef admin fill:#ffb3ba,stroke:#d8000c,stroke-width:2px;
    classDef backup fill:#ffdfba,stroke:#ff7e00,stroke-width:2px;
    classDef backend fill:#caffbf,stroke:#007f5c,stroke-width:2px;
    classDef database fill:#ffffba,stroke:#b58900,stroke-width:2px;
    classDef assets fill:#d3bdf2,stroke:#6c3483,stroke-width:2px;
    classDef cicd fill:#b5ead7,stroke:#379683,stroke-width:2px;
    classDef user fill:#ffcccc,stroke:#cc0000,stroke-width:2px;
```
