Imported from ByShahbazi/Portfolio (
AGENTS.md). Install upstream withnpx skills add ByShahbazi/Portfolio. Copyright stays with the author.
Agent Guide — Shahbazi Portfolio
This file is the source of truth for AI agents working on this repo. Read it before editing. Prefer small, local changes that match existing patterns.
Product
- Personal portfolio for Mohammad Mahdi Shahbazi (محمدمهدی شهبازی), QA Automation Engineer.
- Audience: recruiters / hiring managers scanning dark, mono, emerald engineering aesthetic.
- Live site:
https://byshahbazi.github.io/Portfolio/(base: '/Portfolio/').
Stack
| Layer | Tech |
|---|---|
| UI | React 18 + TypeScript + Vite |
| Motion | Framer Motion (useReducedMotion required) |
| Icons | Custom brand SVGs in components/SkillIcon.tsx (not Lucide for skills) |
| Data | portfolio-data.js + optional Express API (server.js) |
| Deploy | GitHub Actions → Pages (.github/workflows/deploy-pages.yml) |
Hard constraints (do not violate)
- Do not push unless the user explicitly asks.
- Do not commit unless the user explicitly asks.
- Keep visual language: near-black
#050505, emerald accents, mono type. Avoid AI-slop purple/cream/broadsheet looks. - GitHub Pages is static: production must work with
FALLBACK_CONTENT(no API). vite.config.tsbasemust stay'/Portfolio/'.- Persian user replies → wrap prose in
<div dir="rtl">…</div>. - Prefer editing existing files over adding parallel systems.
Architecture (mental model)
index.html → index.tsx → App.tsx
├── Navbar
├── Hero (desktop resume + code scroll cue)
├── ResumeGate (non-desktop resume + code scroll cue)
├── About
├── Skills (+ SkillModal, SkillIcon)
├── Projects
├── Experience
└── Contact
data: portfolio-data.js ← constants.FALLBACK_CONTENT ← App validation
styles: index.css (utility-ish custom CSS, not Tailwind build)
Where to change what
| Goal | Primary files |
|---|---|
| Copy / skills / jobs / contact | portfolio-data.js, then types.ts if shape changes |
| Layout / section UI | matching components/*.tsx + index.css |
| Skill brand icons | components/SkillIcon.tsx only |
| Resume button placement | Hero.tsx (desktop), ResumeGate.tsx (≤1023px) |
| Scroll cue | CodeScrollCue.tsx + .code-scroll-cue* in index.css |
| SEO | index.html, public/robots.txt, public/sitemap.xml |
| Deploy | .github/workflows/deploy-pages.yml |
| Agent docs | AGENTS.md, docs/* |
Responsive rules
- Breakpoint desktop =
min-width: 1024px. - Below 1024px: hide
.hero-actions--desktop, show.resume-gatecentered above About. - Skills: 1-col list rows on small screens; multi-col cards from
640px+. - Always respect
prefers-reduced-motion.
Content / validation
App.tsxvalidates API payloads withisContent/isSkill/isProject.- If you add fields to data, update
types.tsand validators andportfolio-data.js. - Resume file:
public/Resume-Shahbazi.pdf→ URL viagetResumeUrl().
Design taste (portfolio)
- One job per section; avoid card spam in heroes.
- Motion: purposeful (typewriter, scroll cue, reveals), not decorative noise.
- Skills rings use CSS vars
--ring-size,--ring-core,--ring-icon. - Brand skill icons should stay recognizable official marks (>90%), not generic Lucide substitutes.
Commands
npm install
npm run dev # Vite + Express
npm run typecheck
npm run build
npm run preview # serves /Portfolio/ base
Deploy checklist (human)
- Pages source = GitHub Actions (not branch root).
- Push
mainonly when asked. - Confirm built assets load (
/Portfolio/assets/*.js), not rawindex.tsx.
Doc map for agents
- docs/agent-overview.md — workflow + file map
- docs/components.md — every React component
- docs/data-and-types.md — data contract
- docs/styles.md — CSS conventions
- docs/skills.md — Skills section + icons
- docs/about.md
- docs/projects.md
- docs/experience.md
- docs/education.md
- docs/contact.md
- docs/seo.md
- docs/deploy.md
Definition of done (agent)
npm run typecheck/npm run buildpass when UI/data changed.- Mobile + desktop both checked for the touched section.
- No secrets committed.
- Docs updated if behavior/contract changed.