Files
Do SikiandClaude Sonnet 5 758ee2cfed
CI Pipeline with Test Management / đŸ§Ș Run Tests & Generate Reports (push) Canceled after 0s
Test Reporting & Gherkin Analysis / đŸ§Ș Run Tests & Generate Reports (push) Canceled after 0s
CI Pipeline with Test Management / 🐳 Docker Integration Tests (push) Canceled after 0s
CI Pipeline with Test Management / đŸ—ïž Build Docker Image (push) Canceled after 0s
CI Pipeline with Test Management / 📊 Generate Test Summary (push) Canceled after 0s
Test Reporting & Gherkin Analysis / 📊 Analyze Test Coverage (push) Canceled after 0s
Test Reporting & Gherkin Analysis / 🔄 Sync with Linear (push) Canceled after 0s
Test Reporting & Gherkin Analysis / ⚡ Performance Monitoring (push) Canceled after 0s
docs(agent): refresh architecture/CLAUDE.md docs for Payload CMS (MITHOME-95)
The Content layer description across the AI-agent steering docs still
described the pre-migration JSON system as the live, current mechanism
— rule #1 in CLAUDE.md and the Content row in architecture.md
explicitly told future work (and future agent sessions) to edit
proto/src/content/pages/*.json directly, which the live site hasn't
read since MITHOME-91.

Rewrote, per the ticket's named targets:
- .agent/steering/architecture.md: system overview, the Content layer
  table row, rule #1, and the Content Management code example now
  describe Payload Globals/Collections + the payload-content.ts Local
  API adapter, with /admin as the editing surface.
- CLAUDE.md: Stack line now names Payload CMS, rule #1 rewritten the
  same way, and the project-structure tree gets the (frontend)/(payload)
  route groups, globals/, collections/, and payload.config.ts that were
  entirely missing from it.

Also fixed directly-adjacent staleness found while doing this pass —
same "how is content edited" documentation debt, just not literally
named in the ticket:
- .agent/AGENTS.md: same project-structure tree gap as CLAUDE.md.
- .agent/workflows/new-feature.md: step 3 told contributors to edit
  the JSON file directly; now points at the Payload config + admin.
- .agent/workflows/review.md: the example "flag hardcoded text" review
  comment suggested moving it into the JSON file.
- .agent/steering/development-rules.md: the TRADEOFF code example
  literally used "JSON content management vs CMS" as a live open
  decision — that decision is resolved, updated the example to match.
- README.md: the entire "Tartalomkezelés" section and a "CMS
  PublikĂĄlĂĄs gomb" paragraph described the retired content-editor.js
  workflow (git-push-based publish, JSON directory tour) as current;
  also dropped a dead link to docs/felhasznaloi-utmutato.md, deleted
  in MITHOME-93.

Doc-only change, no proto/ source touched — no gate to run beyond a
sanity re-read of each edited file.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-13 12:33:33 +02:00

109 lines
5.1 KiB
Markdown
Executable File

# CLAUDE.md
> **[AI AGENT — OLVASD EL ELƐSZÖR]**
> Ez a fåjl egy gyors referencia. A teljes szabålyrendszer és workflow-ok a `.agent/` mappåban talålhatók.
> **KötelezƑ elolvasni**: `.agent/AGENTS.md` → `.agent/steering/development-rules.md` → `.agent/steering/architecture.md`
---
## Projekt azonosĂ­tĂĄs
- **Projekt**: mozdIT Bt. weboldal (websitedev)
- **Plane workspace**: `developments` — `pm.llmdev.mozdit.hu`
- **Stack**: Next.js 15, React 19, TypeScript, Tailwind CSS 4, Payload CMS (self-hosted, `/admin`), MongoDB, Winston
- **FƑ könyvtĂĄr**: `proto/` — **minden parancsot innen futtatunk**
---
## Gyors referencia — Alapszabályok
1. **Szöveg sosem kerĂŒlhet közvetlenĂŒl komponensbe** → Payload CMS Global/Collection mezƑ (admin: `/admin`), a frontend `proto/src/lib/payload-content.ts`-en ĂĄt olvassa. (`proto/src/content/pages/*.json` mĂĄr csak a migrĂĄciĂłs seed-script forrĂĄsa + teszt-fixture, Ă©lƑ oldal nem hasznĂĄlja — MITHOME-91/93/96.)
2. **Feladatok**: `TODO.md` (Plane tĂŒkörkĂ©pe), szinkron: `node plane-sync.js`
3. **Tesztek**: minden feature-höz kötelezƑ; commit elƑtt `npm test` zöld
4. **Commit**: Conventional Commits (`feat:`, `fix:`, `docs:`, `chore:`)
5. **Fåjlméret**: soft limit 300 sor, hard limit 400 sor
6. **Language**: kĂłd+commit = English, kommunikĂĄciĂł+docs = Magyar
---
## KötelezƑ parancsok (`proto/` mappĂĄbĂłl)
```bash
npm run dev # fejlesztƑi szerver (Turbopack)
npm run build # produkciĂłs build
npm run lint # ESLint ellenƑrzĂ©s
npm test # unit tesztek
npm run test:coverage # lefedettség riport
npm run test:all # teljes test suite
node plane-sync.js --list # Plane projektek listĂĄzĂĄsa
node plane-sync.js # Plane szinkronizĂĄciĂł
```
---
## Projekt struktĂșra
```
websitedev/
├── proto/ # FƑ Next.js alkalmazás
│ └── src/
│ ├── app/
│ │ ├── (frontend)/ # Publikus oldalak: [locale]/[slug] catch-all
│ │ └── (payload)/ # Payload admin (/admin) + REST/GraphQL API
│ ├── components/ # React komponensek (PascalCase.tsx)
│ ├── globals/ # Payload Globals (Home, About, Services, Contact, Common)
│ ├── collections/ # Payload Collections (LegalPages, Partners, Media, ContactSubmissions, Users)
│ ├── payload.config.ts # Payload CMS konfiguráció
│ ├── content/ # RÉGI JSON rendszer — csak migrációs seed + teszt-fixture (MITHOME-91/93/96)
│ │ ├── common.json
│ │ └── pages/
│ ├── lib/ # payload-content.ts (Local API adapter), MongoDB health-check, Logger
│ ├── config/ # Statikus site konfiguráció
│ └── types/ # TypeScript típusok
├── docs/ # Projekt dokumentáció (Magyar)
├── .agent/ # AI szabályrendszer ← OLVASD EL
│ ├── AGENTS.md # ElsƑdleges szabályok
│ ├── steering/ # Auto-betöltƑdƑ irĂĄnyelvek
│ ├── workflows/ # /new-feature, /fix-bug, /review, /deploy
│ └── references/ # Accessibility checklist
├── TODO.md # Feladatlista (Plane szinkron)
└── plane-sync.js # Plane szinkronizáló script
```
---
## Környezeti våltozók
SzĂŒksĂ©ges vĂĄltozĂłk (`.env` Ă©s `proto/.env.local`):
- `MONGODB_URI` — MongoDB connection string
- `MONGODB_DB` — Adatbázis neve (default: `mozdit`)
- `NEXT_PUBLIC_SITE_URL` — Publikus site URL
- `NEXT_PUBLIC_WEBMAIL_URL` — Webmail service URL
- `NEXT_PUBLIC_CONTACT_EMAIL` — Kapcsolati email cím
- `PLANE_API_KEY` — Plane szinkronizációhoz (a `.mcp.json`-ban is lehet)
- `PAYLOAD_SECRET` — Payload CMS JWT/session alĂĄĂ­rĂĄshoz (MITHOME-86); környezetenkĂ©nt egyedi, erƑs Ă©rtĂ©k
- `ADMIN_EMAIL` / `ADMIN_PASSWORD` — staging/production: `deploy.sh` ezekkel hoz lĂ©tre egy ismert admin usert egy vadonatĂșj adatbĂĄzison (MITHOME-97 follow-up), csak akkor, ha a `users` collection mĂ©g ĂŒres
---
## API struktĂșra
- `GET /api/health` — Rendszer ĂĄllapot + MongoDB kapcsolat ellenƑrzĂ©s
- Minden endpoint egységes vålasz formåtumban: `{ success, data, error }`
- Rate limiting érzékeny endpoint-okon (pl. `/api/contact`)
---
## Teljes szabĂĄlyrendszer
| Dokumentum | Tartalom |
| --- | --- |
| `.agent/AGENTS.md` | Összes alapelv, Git konvenciĂłk, mikor kĂ©rdezz |
| `.agent/steering/development-rules.md` | KĂłdolĂĄsi szabĂĄlyok, bugfix mĂłdszertan, intent capture |
| `.agent/steering/architecture.md` | Rétegek, adatfolyam, design system szabålyok |
| `.agent/steering/testing.md` | Tesztelési stratégia, coverage elvåråsok |
| `.agent/workflows/new-feature.md` | Új funkciĂł fejlesztĂ©si lĂ©pĂ©sei |
| `.agent/workflows/fix-bug.md` | Hibajavítås lépései (TDD) |
| `.agent/workflows/review.md` | Code review checklist |
| `.agent/workflows/deploy.md` | Deployment folyamat |
| `.agent/references/accessibility-checklist.md` | WCAG 2.1 AA ellenƑrzƑlista |