summaryrefslogtreecommitdiffstats
path: root/CLAUDE.md
blob: 425894d0b76643ed1d554274fcfd09bcb8a899d8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

## Commands

```bash
# Dev server (live reload)
hugo server

# Production build (output to public/)
hugo build

# Restore PHP contact form deps (after fresh clone)
cd static/api && composer install
```

## Architecture

Single-page bilingual portfolio site (EN/IT). Hugo ≥ 0.120.0 required.

**Data-driven content:** All section content lives in `data/*.yaml` (projects, skills, services, education, certs, contact). Templates in `themes/danixme/layouts/partials/` render these via Hugo's `.Site.Data`. To update site content, edit YAML — not templates.

**Theme:** Custom `themes/danixme/` — no external theme dependency.
- `assets/css/main.css` — ~1763 lines. CSS vars: `--accent` (#a855f7 purple), `--accent2` (#00ff88 neon). Dark mode base; light mode overrides via `.light` class on `<body>`.
- `assets/js/main.js` — contact form AJAX, hero typing effect, dark/light toggle, carousel.
- `layouts/partials/` — one partial per section (hero, about, skills, projects, certs, contact, etc.)

**i18n:** Translation keys in `themes/danixme/i18n/en.toml` and `it.toml`. Use `i18n "key"` in templates; never hardcode visible text.

**Languages:** Configured in `hugo.toml`. Each language has its own `contentDir` (`content/en/`, `content/it/`) and CV path param. The `_index.md` files hold only frontmatter metadata — sections render from YAML data.

**Contact backend:** `static/api/contact.php` uses PHPMailer. Credentials are in `mail-config.php` (gitignored). The PHP file is deployed as-is under `/api/` on the server.

**Static assets:** `static/img/` for images, `static/files/` for downloadable CVs (referenced in `hugo.toml` params per language).