# 6288mani/bala-portfolio architecture

> Architecture diagram of the GitHub repository 6288mani/bala-portfolio, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-14). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/6288mani/bala-portfolio
- Repository: https://github.com/6288mani/bala-portfolio

## Overview

This repository provides a portfolio-facing contact experience backed by an email-sending API. A visitor submits contact details through the React form; the backend validates and rate-limits the request, sends a notification and an acknowledgement through Resend, and returns a result for the form to display. The frontend also contains standalone portfolio interactions for navigation, theme selection, animated backgrounds, and project previews. The supplied excerpts do not show how that script is loaded, nor the implementation of the chat widget, so those connections are omitted.

Main entry points: [`backend/server.js`](https://github.com/6288mani/bala-portfolio/blob/main/backend/server.js) (Contact API), [`frontend/src/ContactForm.jsx`](https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/ContactForm.jsx) (Contact form), [`frontend/src/App.jsx`](https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/App.jsx) (React app shell), [`frontend/src/FloatingChatWidget.jsx`](https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/FloatingChatWidget.jsx) (WhatsApp chat widget)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Portfolio frontend"]
  node_app["React app shell<br/>[App.jsx]"]
  node_form["Contact form<br/>[ContactForm.jsx]"]
  node_chat["WhatsApp chat widget"]
  node_portfolio["Portfolio interactions<br/>[script.js]"]
end

subgraph group_backend["Contact backend"]
  node_api["Contact API<br/>[server.js]"]
end

subgraph group_integrations["External services"]
  node_resend["Resend email service"]
end

node_visitor(("Visitor"))

node_visitor -->|"submits message"| node_form
node_app -->|"renders"| node_form
node_app -->|"renders"| node_chat
node_form -->|"posts contact"| node_api
node_api -->|"sends notification"| node_resend
node_api -->|"sends acknowledgement"| node_resend
node_api -->|"returns result"| node_form

click node_app "https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/App.jsx"
click node_form "https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/ContactForm.jsx"
click node_chat "https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/FloatingChatWidget.jsx"
click node_portfolio "https://github.com/6288mani/bala-portfolio/blob/main/frontend/script.js"
click node_api "https://github.com/6288mani/bala-portfolio/blob/main/backend/server.js"

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_app,node_form,node_chat,node_portfolio toneBlue
class node_api toneAmber
class node_resend toneMint
class node_visitor toneIndigo
```

## Components

### Portfolio frontend

- [React app shell](https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`
- [Contact form](https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/ContactForm.jsx): `frontend/src/ContactForm.jsx`
- [WhatsApp chat widget](https://github.com/6288mani/bala-portfolio/blob/main/frontend/src/FloatingChatWidget.jsx): `frontend/src/FloatingChatWidget.jsx`
- [Portfolio interactions](https://github.com/6288mani/bala-portfolio/blob/main/frontend/script.js): `frontend/script.js`

### Contact backend

- [Contact API](https://github.com/6288mani/bala-portfolio/blob/main/backend/server.js): `backend/server.js`

### External services

- **Resend email service**

### Other components

- **Visitor**

## Connections

- Visitor → Contact form: submits message (evidence: `frontend/src/ContactForm.jsx`)
- React app shell → Contact form: renders (evidence: `frontend/src/App.jsx`)
- React app shell → WhatsApp chat widget: renders (evidence: `frontend/src/App.jsx`)
- Contact form → Contact API: posts contact (evidence: `frontend/src/ContactForm.jsx`)
- Contact API → Resend email service: sends notification (evidence: `backend/server.js`)
- Contact API → Resend email service: sends acknowledgement (evidence: `backend/server.js`)
- Contact API → Contact form: returns result (evidence: `frontend/src/ContactForm.jsx`)
